diff --git a/CODEGEN_VERSION b/CODEGEN_VERSION index 7e6e244735c..3ae784ff4e2 100644 --- a/CODEGEN_VERSION +++ b/CODEGEN_VERSION @@ -1 +1 @@ -16e50491e9d896cb53da4a46080b4333741b76cb \ No newline at end of file +2c60f902831f969f228cecd1f52a81ca240c433c \ No newline at end of file diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 7073706edf3..ade311e7c7a 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v2217 \ No newline at end of file +v2229 \ No newline at end of file diff --git a/src/main/java/com/stripe/ApiVersion.java b/src/main/java/com/stripe/ApiVersion.java index 19c382f62d5..bdd7da73b66 100644 --- a/src/main/java/com/stripe/ApiVersion.java +++ b/src/main/java/com/stripe/ApiVersion.java @@ -2,5 +2,5 @@ package com.stripe; final class ApiVersion { - public static final String CURRENT = "2026-04-01.preview"; + public static final String CURRENT = "2026-04-08.preview"; } diff --git a/src/main/java/com/stripe/exception/CannotProceedException.java b/src/main/java/com/stripe/exception/CannotProceedException.java new file mode 100644 index 00000000000..089992b1865 --- /dev/null +++ b/src/main/java/com/stripe/exception/CannotProceedException.java @@ -0,0 +1,45 @@ +// File generated from our OpenAPI spec +package com.stripe.exception; + +import com.google.gson.JsonObject; +import com.google.gson.annotations.SerializedName; +import com.stripe.model.StripeError; +import com.stripe.model.StripeObject; +import com.stripe.net.StripeResponseGetter; +import lombok.Getter; + +/** Returned when the PayoutMethod object is set as default_for_currency and cannot be archived. */ +public final class CannotProceedException extends ApiException { + private static final long serialVersionUID = 2L; + @Getter String reason; + + private CannotProceedException( + String message, + String requestId, + String code, + Integer statusCode, + Throwable e, + String reason) { + super(message, requestId, code, statusCode, e); + this.reason = reason; + } + + static CannotProceedException parse( + JsonObject body, int statusCode, String requestId, StripeResponseGetter responseGetter) { + CannotProceedException.CannotProceedError error = + (CannotProceedException.CannotProceedError) + StripeObject.deserializeStripeObject( + body, CannotProceedException.CannotProceedError.class, responseGetter); + CannotProceedException exception = + new CannotProceedException( + error.getMessage(), requestId, error.getCode(), statusCode, null, error.getReason()); + exception.setStripeError(error); + return exception; + } + + public static class CannotProceedError extends StripeError { + @Getter + @SerializedName("reason") + String reason; + } +} diff --git a/src/main/java/com/stripe/exception/StripeException.java b/src/main/java/com/stripe/exception/StripeException.java index 2588a593e86..18e92150c16 100644 --- a/src/main/java/com/stripe/exception/StripeException.java +++ b/src/main/java/com/stripe/exception/StripeException.java @@ -122,6 +122,9 @@ public static StripeException parseV2Exception( case "blocked_by_stripe": return com.stripe.exception.BlockedByStripeException.parse( body, statusCode, requestId, responseGetter); + case "cannot_proceed": + return com.stripe.exception.CannotProceedException.parse( + body, statusCode, requestId, responseGetter); case "controlled_by_alternate_resource": return com.stripe.exception.ControlledByAlternateResourceException.parse( body, statusCode, requestId, responseGetter); diff --git a/src/main/java/com/stripe/model/ApplicationFee.java b/src/main/java/com/stripe/model/ApplicationFee.java index 78f77cc748f..e06b478ca7e 100644 --- a/src/main/java/com/stripe/model/ApplicationFee.java +++ b/src/main/java/com/stripe/model/ApplicationFee.java @@ -328,6 +328,10 @@ public static class FeeSource extends StripeObject { @SerializedName("charge") String charge; + /** PaymentRecord ID that created this application fee. */ + @SerializedName("payment_record") + String paymentRecord; + /** Payout ID that created this application fee. */ @SerializedName("payout") String payout; diff --git a/src/main/java/com/stripe/model/Invoice.java b/src/main/java/com/stripe/model/Invoice.java index d4a65bda485..1d034c4d15d 100644 --- a/src/main/java/com/stripe/model/Invoice.java +++ b/src/main/java/com/stripe/model/Invoice.java @@ -2591,6 +2591,13 @@ public static class PaymentMethodOptions extends StripeObject { @SerializedName("bancontact") Bancontact bancontact; + /** + * If paying by {@code bizum}, this sub-hash contains details about the Bizum payment method + * options to pass to the invoice’s PaymentIntent. + */ + @SerializedName("bizum") + Bizum bizum; + /** * If paying by {@code card}, this sub-hash contains details about the Card payment method * options to pass to the invoice’s PaymentIntent. @@ -2716,6 +2723,15 @@ public static class Bancontact extends StripeObject { String preferredLanguage; } + /** + * For more details about Bizum, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Bizum extends StripeObject {} + /** * For more details about Card, please refer to the API * Reference. diff --git a/src/main/java/com/stripe/model/PaymentIntent.java b/src/main/java/com/stripe/model/PaymentIntent.java index f4740007709..605c4b209f0 100644 --- a/src/main/java/com/stripe/model/PaymentIntent.java +++ b/src/main/java/com/stripe/model/PaymentIntent.java @@ -3293,6 +3293,10 @@ public static class PaymentDetails extends StripeObject { @SerializedName("event_details") EventDetails eventDetails; + /** Fleet data for this PaymentIntent. */ + @SerializedName("fleet_data") + List fleetData; + @SerializedName("flight_data") List flightData; @@ -4014,6 +4018,82 @@ public static class Recipient extends StripeObject { } } + /** + * For more details about FleetDatum, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class FleetDatum extends StripeObject { + @SerializedName("primary_fuel_fields") + PrimaryFuelFields primaryFuelFields; + + @SerializedName("station") + Station station; + + @SerializedName("vat") + Vat vat; + + /** + * For more details about PrimaryFuelFields, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class PrimaryFuelFields extends StripeObject { + /** The fuel brand. */ + @SerializedName("brand") + String brand; + } + + /** + * For more details about Station, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Station extends StripeObject { + /** Additional contact information for the station. */ + @SerializedName("additional_contact_info") + String additionalContactInfo; + + /** The customer service phone number of the station. */ + @SerializedName("customer_service_phone_number") + String customerServicePhoneNumber; + + /** The partner ID code of the station. */ + @SerializedName("partner_id_code") + String partnerIdCode; + + /** The phone number of the station. */ + @SerializedName("phone_number") + String phoneNumber; + + @SerializedName("service_location") + com.stripe.model.Address serviceLocation; + + /** The URL of the station. */ + @SerializedName("url") + String url; + } + + /** + * For more details about Vat, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Vat extends StripeObject { + /** Indicates the merchant's agreement for Invoice on Behalf (IOB) VAT processing. */ + @SerializedName("iob_indicator") + String iobIndicator; + } + } + /** * For more details about FlightDatum, please refer to the API Reference. diff --git a/src/main/java/com/stripe/model/PaymentIntentAmountDetailsLineItem.java b/src/main/java/com/stripe/model/PaymentIntentAmountDetailsLineItem.java index 28aac26eba8..ad67f2f45e2 100644 --- a/src/main/java/com/stripe/model/PaymentIntentAmountDetailsLineItem.java +++ b/src/main/java/com/stripe/model/PaymentIntentAmountDetailsLineItem.java @@ -66,6 +66,13 @@ public class PaymentIntentAmountDetailsLineItem extends ApiResource implements H @SerializedName("quantity") Long quantity; + /** + * The number of decimal places implied in the quantity. For example, if quantity is 10000 and + * quantity_precision is 2, the actual quantity is 100.00. Defaults to 0 if not provided. + */ + @SerializedName("quantity_precision") + Long quantityPrecision; + /** Contains information about the tax on the item. */ @SerializedName("tax") Tax tax; @@ -158,6 +165,26 @@ public static class PaymentMethodOptions extends StripeObject { public static class Card extends StripeObject { @SerializedName("commodity_code") String commodityCode; + + @SerializedName("fleet_data") + FleetData fleetData; + + /** + * For more details about FleetData, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class FleetData extends StripeObject { + /** The type of product being purchased at this line item. */ + @SerializedName("product_type") + String productType; + + /** The type of service received at the acceptor location. */ + @SerializedName("service_type") + String serviceType; + } } /** diff --git a/src/main/java/com/stripe/model/PaymentMethod.java b/src/main/java/com/stripe/model/PaymentMethod.java index 5f29c70747b..81a47966329 100644 --- a/src/main/java/com/stripe/model/PaymentMethod.java +++ b/src/main/java/com/stripe/model/PaymentMethod.java @@ -262,6 +262,10 @@ public class PaymentMethod extends ApiResource implements HasId, MetadataStore

API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Bizum extends StripeObject {} + /** * For more details about Card, please refer to the API * Reference. diff --git a/src/main/java/com/stripe/model/Subscription.java b/src/main/java/com/stripe/model/Subscription.java index 9c0703f2864..1c3dab37ee0 100644 --- a/src/main/java/com/stripe/model/Subscription.java +++ b/src/main/java/com/stripe/model/Subscription.java @@ -1980,6 +1980,13 @@ public static class PaymentMethodOptions extends StripeObject { @SerializedName("bancontact") Bancontact bancontact; + /** + * This sub-hash contains details about the Bizum payment method options to pass to invoices + * created by the subscription. + */ + @SerializedName("bizum") + Bizum bizum; + /** * This sub-hash contains details about the Card payment method options to pass to invoices * created by the subscription. @@ -2105,6 +2112,39 @@ public static class Bancontact extends StripeObject { String preferredLanguage; } + /** + * For more details about Bizum, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Bizum extends StripeObject { + @SerializedName("mandate_options") + MandateOptions mandateOptions; + + /** + * For more details about MandateOptions, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class MandateOptions extends StripeObject { + /** Amount to be charged for future payments. Required when {@code amount_type=fixed}. */ + @SerializedName("amount") + Long amount; + + /** + * Indicates the mandate amount type. + * + *

Equal to {@code fixed}. + */ + @SerializedName("amount_type") + String amountType; + } + } + /** * For more details about Card, please refer to the API * Reference. diff --git a/src/main/java/com/stripe/model/delegatedcheckout/RequestedSession.java b/src/main/java/com/stripe/model/delegatedcheckout/RequestedSession.java index 6a8705b9cd6..8170f04f2e7 100644 --- a/src/main/java/com/stripe/model/delegatedcheckout/RequestedSession.java +++ b/src/main/java/com/stripe/model/delegatedcheckout/RequestedSession.java @@ -144,7 +144,7 @@ public class RequestedSession extends ApiResource /** * The status of the requested session. * - *

One of {@code completed}, {@code expired}, or {@code open}. + *

One of {@code completed}, {@code expired}, {@code open}, or {@code requires_action}. */ @SerializedName("status") String status; diff --git a/src/main/java/com/stripe/model/radar/CustomerEvaluation.java b/src/main/java/com/stripe/model/radar/CustomerEvaluation.java index 27c22cadc9a..c36eb80648c 100644 --- a/src/main/java/com/stripe/model/radar/CustomerEvaluation.java +++ b/src/main/java/com/stripe/model/radar/CustomerEvaluation.java @@ -29,11 +29,15 @@ public class CustomerEvaluation extends ApiResource implements HasId { @SerializedName("created_at") Long createdAt; - /** The ID of the Stripe customer the customer evaluation is associated with. */ + /** The ID of the Customer to associate with this CustomerEvaluation. */ @SerializedName("customer") String customer; - /** The type of evaluation event. */ + /** + * The type of evaluation event. + * + *

One of {@code login}, or {@code registration}. + */ @SerializedName("event_type") String eventType; @@ -61,7 +65,7 @@ public class CustomerEvaluation extends ApiResource implements HasId { @SerializedName("object") String object; - /** A hash of signal objects providing Radar's evaluation for the lifecycle event. */ + /** A hash of signal objects providing Radar's evaluation of the customer. */ @SerializedName("signals") Signals signals; @@ -203,11 +207,16 @@ public static class AccountSharing extends StripeObject { @SerializedName("evaluated_at") Long evaluatedAt; - /** The risk level for this signal. */ + /** + * The risk level for this signal. + * + *

One of {@code elevated}, {@code highest}, {@code low}, {@code normal}, {@code + * not_assessed}, or {@code unknown}. + */ @SerializedName("risk_level") String riskLevel; - /** Score for this signal (float between 0.0-100.0). */ + /** Score for this signal (between 0.0 and 100.0). */ @SerializedName("score") BigDecimal score; } @@ -224,11 +233,16 @@ public static class MultiAccounting extends StripeObject { @SerializedName("evaluated_at") Long evaluatedAt; - /** The risk level for this signal. */ + /** + * The risk level for this signal. + * + *

One of {@code elevated}, {@code highest}, {@code low}, {@code normal}, {@code + * not_assessed}, or {@code unknown}. + */ @SerializedName("risk_level") String riskLevel; - /** Score for this signal (float between 0.0-100.0). */ + /** Score for this signal (between 0.0 and 100.0). */ @SerializedName("score") BigDecimal score; } diff --git a/src/main/java/com/stripe/model/radar/PaymentEvaluation.java b/src/main/java/com/stripe/model/radar/PaymentEvaluation.java index bc881239003..fa67e199d3e 100644 --- a/src/main/java/com/stripe/model/radar/PaymentEvaluation.java +++ b/src/main/java/com/stripe/model/radar/PaymentEvaluation.java @@ -151,6 +151,13 @@ public static PaymentEvaluation create( @Setter @EqualsAndHashCode(callSuper = false) public static class ClientDeviceMetadataDetails extends StripeObject { + /** + * Direct client device attributes such as IP address and user agent. Use this as an alternative + * to radar_session when a Radar Session isn't available. + */ + @SerializedName("data") + Data data; + /** * ID for the Radar Session associated with the payment evaluation. A Radar Session is a snapshot of the @@ -159,6 +166,35 @@ public static class ClientDeviceMetadataDetails extends StripeObject { */ @SerializedName("radar_session") String radarSession; + + /** + * Direct client device attributes such as IP address and user agent. Use this as an alternative + * to radar_session when a Radar Session isn't available. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Data extends StripeObject { + /** The IP address of the client device. */ + @SerializedName("ip") + String ip; + + /** Pasted fields from the checkout flow. */ + @SerializedName("pasted_fields") + List pastedFields; + + /** The referrer of the client device. */ + @SerializedName("referrer") + String referrer; + + /** The time on page in milliseconds. */ + @SerializedName("time_on_page_ms") + Long timeOnPageMs; + + /** The user agent of the client device. */ + @SerializedName("user_agent") + String userAgent; + } } /** Customer details attached to this payment evaluation. */ diff --git a/src/main/java/com/stripe/model/sharedpayment/GrantedToken.java b/src/main/java/com/stripe/model/sharedpayment/GrantedToken.java index 88613c91d3d..b74828b38dd 100644 --- a/src/main/java/com/stripe/model/sharedpayment/GrantedToken.java +++ b/src/main/java/com/stripe/model/sharedpayment/GrantedToken.java @@ -328,6 +328,9 @@ public static class PaymentMethodDetails extends StripeObject { @SerializedName("stripe_balance") StripeBalance stripeBalance; + @SerializedName("sunbit") + Sunbit sunbit; + @SerializedName("swish") Swish swish; @@ -350,8 +353,8 @@ public static class PaymentMethodDetails extends StripeObject { * pay_by_bank}, {@code payco}, {@code paynow}, {@code paypal}, {@code paypay}, {@code payto}, * {@code pix}, {@code promptpay}, {@code qris}, {@code rechnung}, {@code revolut_pay}, {@code * samsung_pay}, {@code satispay}, {@code sepa_debit}, {@code shopeepay}, {@code sofort}, {@code - * stripe_balance}, {@code swish}, {@code twint}, {@code upi}, {@code us_bank_account}, {@code - * wechat_pay}, or {@code zip}. + * stripe_balance}, {@code sunbit}, {@code swish}, {@code twint}, {@code upi}, {@code + * us_bank_account}, {@code wechat_pay}, or {@code zip}. */ @SerializedName("type") String type; @@ -1881,6 +1884,15 @@ public static class StripeBalance extends StripeObject { String account; } + /** + * For more details about Sunbit, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Sunbit extends StripeObject {} + /** * For more details about Swish, please refer to the API * Reference. diff --git a/src/main/java/com/stripe/model/v2/core/Account.java b/src/main/java/com/stripe/model/v2/core/Account.java index 0f5c3dd7de1..22e69eed313 100644 --- a/src/main/java/com/stripe/model/v2/core/Account.java +++ b/src/main/java/com/stripe/model/v2/core/Account.java @@ -8874,30 +8874,25 @@ public static class IdNumber extends StripeObject { *

One of {@code ae_crn}, {@code ae_vat}, {@code ao_nif}, {@code ar_cuit}, {@code at_fn}, * {@code at_stn}, {@code at_vat}, {@code au_abn}, {@code au_acn}, {@code au_in}, {@code * az_tin}, {@code bd_etin}, {@code be_cbe}, {@code be_vat}, {@code bg_uic}, {@code bg_vat}, - * {@code bm_crn}, {@code bo_tin}, {@code br_cnpj}, {@code bt_tpn}, {@code ca_cn}, {@code - * ca_crarr}, {@code ca_gst_hst}, {@code ca_neq}, {@code ca_rid}, {@code ch_chid}, {@code - * ch_uid}, {@code co_nit}, {@code cr_cpj}, {@code cr_nite}, {@code cy_he}, {@code cy_tic}, - * {@code cy_vat}, {@code cz_ico}, {@code cz_vat}, {@code de_hrn}, {@code de_stn}, {@code - * de_vat}, {@code dk_cvr}, {@code dk_vat}, {@code do_rcn}, {@code ec_ruc}, {@code ee_rk}, - * {@code ee_vat}, {@code eg_tin}, {@code es_cif}, {@code es_vat}, {@code fi_vat}, {@code - * fi_yt}, {@code fr_rna}, {@code fr_siren}, {@code fr_vat}, {@code gb_crn}, {@code gb_vat}, - * {@code gh_tin}, {@code gi_crn}, {@code gr_afm}, {@code gr_gemi}, {@code gr_vat}, {@code - * gt_nit}, {@code gy_tin}, {@code hk_br}, {@code hk_cr}, {@code hn_rtn}, {@code hr_mbs}, - * {@code hr_oib}, {@code hr_vat}, {@code hu_cjs}, {@code hu_tin}, {@code hu_vat}, {@code - * ie_crn}, {@code ie_trn}, {@code ie_vat}, {@code it_rea}, {@code it_vat}, {@code jm_trn}, - * {@code jo_crn}, {@code jp_cn}, {@code ke_pin}, {@code ky_crn}, {@code kz_bin}, {@code - * li_uid}, {@code lk_tin}, {@code lt_ccrn}, {@code lt_vat}, {@code lu_nif}, {@code lu_rcs}, - * {@code lu_vat}, {@code lv_urn}, {@code lv_vat}, {@code mo_tin}, {@code mt_crn}, {@code - * mt_tin}, {@code mt_vat}, {@code mv_tin}, {@code mx_rfc}, {@code my_brn}, {@code my_coid}, - * {@code my_itn}, {@code my_sst}, {@code mz_nuit}, {@code ng_tin}, {@code nl_kvk}, {@code + * {@code br_cnpj}, {@code ca_cn}, {@code ca_crarr}, {@code ca_gst_hst}, {@code ca_neq}, + * {@code ca_rid}, {@code ch_chid}, {@code ch_uid}, {@code cr_cpj}, {@code cr_nite}, {@code + * cy_he}, {@code cy_tic}, {@code cy_vat}, {@code cz_ico}, {@code cz_vat}, {@code de_hrn}, + * {@code de_stn}, {@code de_vat}, {@code dk_cvr}, {@code dk_vat}, {@code do_rcn}, {@code + * ee_rk}, {@code ee_vat}, {@code es_cif}, {@code es_vat}, {@code fi_vat}, {@code fi_yt}, + * {@code fr_rna}, {@code fr_siren}, {@code fr_vat}, {@code gb_crn}, {@code gb_vat}, {@code + * gi_crn}, {@code gr_afm}, {@code gr_gemi}, {@code gr_vat}, {@code gt_nit}, {@code hk_br}, + * {@code hk_cr}, {@code hr_mbs}, {@code hr_oib}, {@code hr_vat}, {@code hu_cjs}, {@code + * hu_tin}, {@code hu_vat}, {@code ie_crn}, {@code ie_trn}, {@code ie_vat}, {@code it_rea}, + * {@code it_vat}, {@code jp_cn}, {@code kz_bin}, {@code li_uid}, {@code lt_ccrn}, {@code + * lt_vat}, {@code lu_nif}, {@code lu_rcs}, {@code lu_vat}, {@code lv_urn}, {@code lv_vat}, + * {@code mt_crn}, {@code mt_tin}, {@code mt_vat}, {@code mx_rfc}, {@code my_brn}, {@code + * my_coid}, {@code my_itn}, {@code my_sst}, {@code mz_nuit}, {@code nl_kvk}, {@code * nl_rsin}, {@code nl_vat}, {@code no_orgnr}, {@code nz_bn}, {@code nz_ird}, {@code - * pa_ruc}, {@code pe_ruc}, {@code ph_tin}, {@code pk_ntn}, {@code pl_nip}, {@code - * pl_regon}, {@code pl_vat}, {@code pt_vat}, {@code py_ruc}, {@code ro_cui}, {@code - * ro_orc}, {@code ro_vat}, {@code sa_crn}, {@code sa_tin}, {@code se_orgnr}, {@code - * se_vat}, {@code sg_uen}, {@code si_msp}, {@code si_tin}, {@code si_vat}, {@code sk_dic}, - * {@code sk_ico}, {@code sk_vat}, {@code sl_tin}, {@code sv_nit}, {@code th_crn}, {@code - * th_prn}, {@code th_tin}, {@code us_ein}, {@code uy_ruc}, {@code vg_cn}, or {@code - * za_tin}. + * pe_ruc}, {@code pk_ntn}, {@code pl_nip}, {@code pl_regon}, {@code pl_vat}, {@code + * pt_vat}, {@code ro_cui}, {@code ro_orc}, {@code ro_vat}, {@code sa_crn}, {@code sa_tin}, + * {@code se_orgnr}, {@code se_vat}, {@code sg_uen}, {@code si_msp}, {@code si_tin}, {@code + * si_vat}, {@code sk_dic}, {@code sk_ico}, {@code sk_vat}, {@code th_crn}, {@code th_prn}, + * {@code th_tin}, or {@code us_ein}. */ @SerializedName("type") String type; @@ -9581,23 +9576,19 @@ public static class IdNumber extends StripeObject { * *

One of {@code ae_eid}, {@code ao_nif}, {@code ar_cuil}, {@code ar_dni}, {@code * at_stn}, {@code az_tin}, {@code bd_brc}, {@code bd_etin}, {@code bd_nid}, {@code be_nrn}, - * {@code bg_ucn}, {@code bm_pp}, {@code bn_nric}, {@code bo_ci}, {@code br_cpf}, {@code - * bt_cid}, {@code ca_sin}, {@code ch_oasi}, {@code cl_rut}, {@code cn_pp}, {@code co_nuip}, - * {@code cr_ci}, {@code cr_cpf}, {@code cr_dimex}, {@code cr_nite}, {@code cy_tic}, {@code - * cz_rc}, {@code de_stn}, {@code dk_cpr}, {@code do_cie}, {@code do_rcn}, {@code ec_ci}, - * {@code ee_ik}, {@code eg_tin}, {@code es_nif}, {@code fi_hetu}, {@code fr_nir}, {@code - * gb_nino}, {@code gh_pin}, {@code gr_afm}, {@code gt_nit}, {@code gy_tin}, {@code hk_id}, - * {@code hn_rtn}, {@code hr_oib}, {@code hu_ad}, {@code id_nik}, {@code ie_ppsn}, {@code - * is_kt}, {@code it_cf}, {@code jm_trn}, {@code jo_pin}, {@code jp_inc}, {@code ke_pin}, - * {@code ky_pp}, {@code kz_iin}, {@code li_peid}, {@code lk_nic}, {@code lt_ak}, {@code - * lu_nif}, {@code lv_pk}, {@code mo_bir}, {@code mt_nic}, {@code mv_tin}, {@code mx_rfc}, - * {@code my_nric}, {@code mz_nuit}, {@code ng_nin}, {@code nl_bsn}, {@code no_nin}, {@code - * nz_ird}, {@code pa_ruc}, {@code pe_dni}, {@code ph_tin}, {@code pk_cnic}, {@code - * pk_snic}, {@code pl_pesel}, {@code pt_nif}, {@code py_ruc}, {@code ro_cnp}, {@code - * sa_tin}, {@code se_pin}, {@code sg_fin}, {@code sg_nric}, {@code si_pin}, {@code sk_dic}, - * {@code sv_nit}, {@code th_lc}, {@code th_pin}, {@code tr_tin}, {@code us_itin}, {@code - * us_itin_last_4}, {@code us_ssn}, {@code us_ssn_last_4}, {@code uy_dni}, {@code vg_pp}, or - * {@code za_id}. + * {@code bg_ucn}, {@code bn_nric}, {@code br_cpf}, {@code ca_sin}, {@code ch_oasi}, {@code + * cl_rut}, {@code cn_pp}, {@code co_nuip}, {@code cr_ci}, {@code cr_cpf}, {@code cr_dimex}, + * {@code cr_nite}, {@code cy_tic}, {@code cz_rc}, {@code de_stn}, {@code dk_cpr}, {@code + * do_cie}, {@code do_rcn}, {@code ec_ci}, {@code ee_ik}, {@code es_nif}, {@code fi_hetu}, + * {@code fr_nir}, {@code gb_nino}, {@code gr_afm}, {@code gt_nit}, {@code hk_id}, {@code + * hr_oib}, {@code hu_ad}, {@code id_nik}, {@code ie_ppsn}, {@code is_kt}, {@code it_cf}, + * {@code jp_inc}, {@code ke_pin}, {@code kz_iin}, {@code li_peid}, {@code lt_ak}, {@code + * lu_nif}, {@code lv_pk}, {@code mx_rfc}, {@code my_nric}, {@code mz_nuit}, {@code ng_nin}, + * {@code nl_bsn}, {@code no_nin}, {@code nz_ird}, {@code pe_dni}, {@code pk_cnic}, {@code + * pk_snic}, {@code pl_pesel}, {@code pt_nif}, {@code ro_cnp}, {@code sa_tin}, {@code + * se_pin}, {@code sg_fin}, {@code sg_nric}, {@code sk_dic}, {@code th_lc}, {@code th_pin}, + * {@code tr_tin}, {@code us_itin}, {@code us_itin_last_4}, {@code us_ssn}, {@code + * us_ssn_last_4}, {@code uy_dni}, or {@code za_id}. */ @SerializedName("type") String type; diff --git a/src/main/java/com/stripe/model/v2/core/AccountPerson.java b/src/main/java/com/stripe/model/v2/core/AccountPerson.java index 71fc2a61202..25eed6ceaab 100644 --- a/src/main/java/com/stripe/model/v2/core/AccountPerson.java +++ b/src/main/java/com/stripe/model/v2/core/AccountPerson.java @@ -533,22 +533,19 @@ public static class IdNumber extends StripeObject { * *

One of {@code ae_eid}, {@code ao_nif}, {@code ar_cuil}, {@code ar_dni}, {@code at_stn}, * {@code az_tin}, {@code bd_brc}, {@code bd_etin}, {@code bd_nid}, {@code be_nrn}, {@code - * bg_ucn}, {@code bm_pp}, {@code bn_nric}, {@code bo_ci}, {@code br_cpf}, {@code bt_cid}, - * {@code ca_sin}, {@code ch_oasi}, {@code cl_rut}, {@code cn_pp}, {@code co_nuip}, {@code - * cr_ci}, {@code cr_cpf}, {@code cr_dimex}, {@code cr_nite}, {@code cy_tic}, {@code cz_rc}, - * {@code de_stn}, {@code dk_cpr}, {@code do_cie}, {@code do_rcn}, {@code ec_ci}, {@code ee_ik}, - * {@code eg_tin}, {@code es_nif}, {@code fi_hetu}, {@code fr_nir}, {@code gb_nino}, {@code - * gh_pin}, {@code gr_afm}, {@code gt_nit}, {@code gy_tin}, {@code hk_id}, {@code hn_rtn}, - * {@code hr_oib}, {@code hu_ad}, {@code id_nik}, {@code ie_ppsn}, {@code is_kt}, {@code it_cf}, - * {@code jm_trn}, {@code jo_pin}, {@code jp_inc}, {@code ke_pin}, {@code ky_pp}, {@code - * kz_iin}, {@code li_peid}, {@code lk_nic}, {@code lt_ak}, {@code lu_nif}, {@code lv_pk}, - * {@code mo_bir}, {@code mt_nic}, {@code mv_tin}, {@code mx_rfc}, {@code my_nric}, {@code - * mz_nuit}, {@code ng_nin}, {@code nl_bsn}, {@code no_nin}, {@code nz_ird}, {@code pa_ruc}, - * {@code pe_dni}, {@code ph_tin}, {@code pk_cnic}, {@code pk_snic}, {@code pl_pesel}, {@code - * pt_nif}, {@code py_ruc}, {@code ro_cnp}, {@code sa_tin}, {@code se_pin}, {@code sg_fin}, - * {@code sg_nric}, {@code si_pin}, {@code sk_dic}, {@code sv_nit}, {@code th_lc}, {@code - * th_pin}, {@code tr_tin}, {@code us_itin}, {@code us_itin_last_4}, {@code us_ssn}, {@code - * us_ssn_last_4}, {@code uy_dni}, {@code vg_pp}, or {@code za_id}. + * bg_ucn}, {@code bn_nric}, {@code br_cpf}, {@code ca_sin}, {@code ch_oasi}, {@code cl_rut}, + * {@code cn_pp}, {@code co_nuip}, {@code cr_ci}, {@code cr_cpf}, {@code cr_dimex}, {@code + * cr_nite}, {@code cy_tic}, {@code cz_rc}, {@code de_stn}, {@code dk_cpr}, {@code do_cie}, + * {@code do_rcn}, {@code ec_ci}, {@code ee_ik}, {@code es_nif}, {@code fi_hetu}, {@code + * fr_nir}, {@code gb_nino}, {@code gr_afm}, {@code gt_nit}, {@code hk_id}, {@code hr_oib}, + * {@code hu_ad}, {@code id_nik}, {@code ie_ppsn}, {@code is_kt}, {@code it_cf}, {@code jp_inc}, + * {@code ke_pin}, {@code kz_iin}, {@code li_peid}, {@code lt_ak}, {@code lu_nif}, {@code + * lv_pk}, {@code mx_rfc}, {@code my_nric}, {@code mz_nuit}, {@code ng_nin}, {@code nl_bsn}, + * {@code no_nin}, {@code nz_ird}, {@code pe_dni}, {@code pk_cnic}, {@code pk_snic}, {@code + * pl_pesel}, {@code pt_nif}, {@code ro_cnp}, {@code sa_tin}, {@code se_pin}, {@code sg_fin}, + * {@code sg_nric}, {@code sk_dic}, {@code th_lc}, {@code th_pin}, {@code tr_tin}, {@code + * us_itin}, {@code us_itin_last_4}, {@code us_ssn}, {@code us_ssn_last_4}, {@code uy_dni}, or + * {@code za_id}. */ @SerializedName("type") String type; diff --git a/src/main/java/com/stripe/param/ChargeCaptureParams.java b/src/main/java/com/stripe/param/ChargeCaptureParams.java index 4a495e62578..4889ded2821 100644 --- a/src/main/java/com/stripe/param/ChargeCaptureParams.java +++ b/src/main/java/com/stripe/param/ChargeCaptureParams.java @@ -332,6 +332,10 @@ public static class PaymentDetails { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; + /** Fleet data for this PaymentIntent. */ + @SerializedName("fleet_data") + Object fleetData; + /** Flight reservation details for this PaymentIntent. */ @SerializedName("flight") Flight flight; @@ -373,6 +377,7 @@ private PaymentDetails( Object customerReference, EventDetails eventDetails, Map extraParams, + Object fleetData, Flight flight, Object flightData, Lodging lodging, @@ -385,6 +390,7 @@ private PaymentDetails( this.customerReference = customerReference; this.eventDetails = eventDetails; this.extraParams = extraParams; + this.fleetData = fleetData; this.flight = flight; this.flightData = flightData; this.lodging = lodging; @@ -409,6 +415,8 @@ public static class Builder { private Map extraParams; + private Object fleetData; + private Flight flight; private Object flightData; @@ -431,6 +439,7 @@ public ChargeCaptureParams.PaymentDetails build() { this.customerReference, this.eventDetails, this.extraParams, + this.fleetData, this.flight, this.flightData, this.lodging, @@ -543,6 +552,46 @@ public Builder putAllExtraParam(Map map) { return this; } + /** + * Add an element to `fleetData` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * ChargeCaptureParams.PaymentDetails#fleetData} for the field documentation. + */ + @SuppressWarnings("unchecked") + public Builder addFleetData(ChargeCaptureParams.PaymentDetails.FleetData element) { + if (this.fleetData == null || this.fleetData instanceof EmptyParam) { + this.fleetData = new ArrayList(); + } + ((List) this.fleetData).add(element); + return this; + } + + /** + * Add all elements to `fleetData` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeCaptureParams.PaymentDetails#fleetData} for the field documentation. + */ + @SuppressWarnings("unchecked") + public Builder addAllFleetData(List elements) { + if (this.fleetData == null || this.fleetData instanceof EmptyParam) { + this.fleetData = new ArrayList(); + } + ((List) this.fleetData).addAll(elements); + return this; + } + + /** Fleet data for this PaymentIntent. */ + public Builder setFleetData(EmptyParam fleetData) { + this.fleetData = fleetData; + return this; + } + + /** Fleet data for this PaymentIntent. */ + public Builder setFleetData(List fleetData) { + this.fleetData = fleetData; + return this; + } + /** Flight reservation details for this PaymentIntent. */ public Builder setFlight(ChargeCaptureParams.PaymentDetails.Flight flight) { this.flight = flight; @@ -5049,29 +5098,7 @@ public enum Mode implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class Flight { - /** Affiliate details for this purchase. */ - @SerializedName("affiliate") - Affiliate affiliate; - - /** - * The agency number (i.e. International Air Transport Association (IATA) agency number) of - * the travel agency that made the booking. - */ - @SerializedName("agency_number") - String agencyNumber; - - /** - * The International Air Transport Association (IATA) carrier code of the carrier that issued - * the ticket. - */ - @SerializedName("carrier") - String carrier; - - /** Delivery details for this purchase. */ - @SerializedName("delivery") - Delivery delivery; - + public static class FleetData { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -5081,41 +5108,27 @@ public static class Flight { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** The name of the person or entity on the reservation. */ - @SerializedName("passenger_name") - String passengerName; - - /** The details of the passengers in the travel reservation. */ - @SerializedName("passengers") - List passengers; + /** Primary fuel fields for the transaction. */ + @SerializedName("primary_fuel_fields") + PrimaryFuelFields primaryFuelFields; - /** Required. The individual flight segments associated with the trip. */ - @SerializedName("segments") - List segments; + /** Station and acceptor location details. */ + @SerializedName("station") + Station station; - /** The ticket number associated with the travel reservation. */ - @SerializedName("ticket_number") - String ticketNumber; + /** VAT and Invoice on Behalf (IOB) details. */ + @SerializedName("vat") + Vat vat; - private Flight( - Affiliate affiliate, - String agencyNumber, - String carrier, - Delivery delivery, + private FleetData( Map extraParams, - String passengerName, - List passengers, - List segments, - String ticketNumber) { - this.affiliate = affiliate; - this.agencyNumber = agencyNumber; - this.carrier = carrier; - this.delivery = delivery; + PrimaryFuelFields primaryFuelFields, + Station station, + Vat vat) { this.extraParams = extraParams; - this.passengerName = passengerName; - this.passengers = passengers; - this.segments = segments; - this.ticketNumber = ticketNumber; + this.primaryFuelFields = primaryFuelFields; + this.station = station; + this.vat = vat; } public static Builder builder() { @@ -5123,72 +5136,24 @@ public static Builder builder() { } public static class Builder { - private Affiliate affiliate; - - private String agencyNumber; - - private String carrier; - - private Delivery delivery; - private Map extraParams; - private String passengerName; - - private List passengers; + private PrimaryFuelFields primaryFuelFields; - private List segments; + private Station station; - private String ticketNumber; + private Vat vat; /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.Flight build() { - return new ChargeCaptureParams.PaymentDetails.Flight( - this.affiliate, - this.agencyNumber, - this.carrier, - this.delivery, - this.extraParams, - this.passengerName, - this.passengers, - this.segments, - this.ticketNumber); - } - - /** Affiliate details for this purchase. */ - public Builder setAffiliate(ChargeCaptureParams.PaymentDetails.Flight.Affiliate affiliate) { - this.affiliate = affiliate; - return this; - } - - /** - * The agency number (i.e. International Air Transport Association (IATA) agency number) of - * the travel agency that made the booking. - */ - public Builder setAgencyNumber(String agencyNumber) { - this.agencyNumber = agencyNumber; - return this; - } - - /** - * The International Air Transport Association (IATA) carrier code of the carrier that - * issued the ticket. - */ - public Builder setCarrier(String carrier) { - this.carrier = carrier; - return this; - } - - /** Delivery details for this purchase. */ - public Builder setDelivery(ChargeCaptureParams.PaymentDetails.Flight.Delivery delivery) { - this.delivery = delivery; - return this; + public ChargeCaptureParams.PaymentDetails.FleetData build() { + return new ChargeCaptureParams.PaymentDetails.FleetData( + this.extraParams, this.primaryFuelFields, this.station, this.vat); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.Flight#extraParams} for the field + * map. See {@link ChargeCaptureParams.PaymentDetails.FleetData#extraParams} for the field * documentation. */ public Builder putExtraParam(String key, Object value) { @@ -5202,7 +5167,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.Flight#extraParams} for the field + * map. See {@link ChargeCaptureParams.PaymentDetails.FleetData#extraParams} for the field * documentation. */ public Builder putAllExtraParam(Map map) { @@ -5213,76 +5178,33 @@ public Builder putAllExtraParam(Map map) { return this; } - /** The name of the person or entity on the reservation. */ - public Builder setPassengerName(String passengerName) { - this.passengerName = passengerName; - return this; - } - - /** - * Add an element to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeCaptureParams.PaymentDetails.Flight#passengers} for the field documentation. - */ - public Builder addPassenger(ChargeCaptureParams.PaymentDetails.Flight.Passenger element) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.add(element); - return this; - } - - /** - * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeCaptureParams.PaymentDetails.Flight#passengers} for the field documentation. - */ - public Builder addAllPassenger( - List elements) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.addAll(elements); - return this; - } - - /** - * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * ChargeCaptureParams.PaymentDetails.Flight#segments} for the field documentation. - */ - public Builder addSegment(ChargeCaptureParams.PaymentDetails.Flight.Segment element) { - if (this.segments == null) { - this.segments = new ArrayList<>(); - } - this.segments.add(element); + /** Primary fuel fields for the transaction. */ + public Builder setPrimaryFuelFields( + ChargeCaptureParams.PaymentDetails.FleetData.PrimaryFuelFields primaryFuelFields) { + this.primaryFuelFields = primaryFuelFields; return this; } - /** - * Add all elements to `segments` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeCaptureParams.PaymentDetails.Flight#segments} for the field documentation. - */ - public Builder addAllSegment( - List elements) { - if (this.segments == null) { - this.segments = new ArrayList<>(); - } - this.segments.addAll(elements); + /** Station and acceptor location details. */ + public Builder setStation(ChargeCaptureParams.PaymentDetails.FleetData.Station station) { + this.station = station; return this; } - /** The ticket number associated with the travel reservation. */ - public Builder setTicketNumber(String ticketNumber) { - this.ticketNumber = ticketNumber; + /** VAT and Invoice on Behalf (IOB) details. */ + public Builder setVat(ChargeCaptureParams.PaymentDetails.FleetData.Vat vat) { + this.vat = vat; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Affiliate { + public static class PrimaryFuelFields { + /** The fuel brand. */ + @SerializedName("brand") + Brand brand; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -5293,13 +5215,9 @@ public static class Affiliate { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Required. The name of the affiliate that originated the purchase. */ - @SerializedName("name") - String name; - - private Affiliate(Map extraParams, String name) { + private PrimaryFuelFields(Brand brand, Map extraParams) { + this.brand = brand; this.extraParams = extraParams; - this.name = name; } public static Builder builder() { @@ -5307,21 +5225,29 @@ public static Builder builder() { } public static class Builder { - private Map extraParams; + private Brand brand; - private String name; + private Map extraParams; /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.Flight.Affiliate build() { - return new ChargeCaptureParams.PaymentDetails.Flight.Affiliate( - this.extraParams, this.name); + public ChargeCaptureParams.PaymentDetails.FleetData.PrimaryFuelFields build() { + return new ChargeCaptureParams.PaymentDetails.FleetData.PrimaryFuelFields( + this.brand, this.extraParams); + } + + /** The fuel brand. */ + public Builder setBrand( + ChargeCaptureParams.PaymentDetails.FleetData.PrimaryFuelFields.Brand brand) { + this.brand = brand; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.Flight.Affiliate#extraParams} for - * the field documentation. + * map. See {@link + * ChargeCaptureParams.PaymentDetails.FleetData.PrimaryFuelFields#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -5334,8 +5260,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.Flight.Affiliate#extraParams} for - * the field documentation. + * map. See {@link + * ChargeCaptureParams.PaymentDetails.FleetData.PrimaryFuelFields#extraParams} for the + * field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -5344,64 +5271,516 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } - - /** Required. The name of the affiliate that originated the purchase. */ - public Builder setName(String name) { - this.name = name; - return this; - } } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Delivery { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public enum Brand implements ApiRequestParams.EnumParam { + @SerializedName("aafes") + AAFES("aafes"), - /** The delivery method for the payment. */ - @SerializedName("mode") - Mode mode; + @SerializedName("amerada_hess") + AMERADA_HESS("amerada_hess"), - /** Details of the recipient. */ - @SerializedName("recipient") - Recipient recipient; + @SerializedName("amoco_canada") + AMOCO_CANADA("amoco_canada"), - private Delivery(Map extraParams, Mode mode, Recipient recipient) { - this.extraParams = extraParams; - this.mode = mode; - this.recipient = recipient; - } + @SerializedName("amoco_petroleum_products") + AMOCO_PETROLEUM_PRODUCTS("amoco_petroleum_products"), - public static Builder builder() { - return new Builder(); - } + @SerializedName("arco_products") + ARCO_PRODUCTS("arco_products"), - public static class Builder { - private Map extraParams; + @SerializedName("asda") + ASDA("asda"), - private Mode mode; + @SerializedName("ashland_oil") + ASHLAND_OIL("ashland_oil"), - private Recipient recipient; + @SerializedName("bfl") + BFL("bfl"), - /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.Flight.Delivery build() { - return new ChargeCaptureParams.PaymentDetails.Flight.Delivery( - this.extraParams, this.mode, this.recipient); + @SerializedName("bp_mobil") + BP_MOBIL("bp_mobil"), + + @SerializedName("bp_oil") + BP_OIL("bp_oil"), + + @SerializedName("burrnah_major") + BURRNAH_MAJOR("burrnah_major"), + + @SerializedName("butler_arndale") + BUTLER_ARNDALE("butler_arndale"), + + @SerializedName("canadian_tire") + CANADIAN_TIRE("canadian_tire"), + + @SerializedName("canadian_turbo") + CANADIAN_TURBO("canadian_turbo"), + + @SerializedName("caseys_general_store") + CASEYS_GENERAL_STORE("caseys_general_store"), + + @SerializedName("cenex") + CENEX("cenex"), + + @SerializedName("chevron_canada") + CHEVRON_CANADA("chevron_canada"), + + @SerializedName("chevron_usa") + CHEVRON_USA("chevron_usa"), + + @SerializedName("circle_k_stores") + CIRCLE_K_STORES("circle_k_stores"), + + @SerializedName("citgo_petroleum") + CITGO_PETROLEUM("citgo_petroleum"), + + @SerializedName("clark_brands") + CLARK_BRANDS("clark_brands"), + + @SerializedName("conoco_canada") + CONOCO_CANADA("conoco_canada"), + + @SerializedName("conoco_inc") + CONOCO_INC("conoco_inc"), + + @SerializedName("crown_central_petroleum") + CROWN_CENTRAL_PETROLEUM("crown_central_petroleum"), + + @SerializedName("diamond_shamrock_inc") + DIAMOND_SHAMROCK_INC("diamond_shamrock_inc"), + + @SerializedName("discount_tire") + DISCOUNT_TIRE("discount_tire"), + + @SerializedName("domo_gas") + DOMO_GAS("domo_gas"), + + @SerializedName("elf") + ELF("elf"), + + @SerializedName("erickson_oil") + ERICKSON_OIL("erickson_oil"), + + @SerializedName("esso") + ESSO("esso"), + + @SerializedName("esso_canada") + ESSO_CANADA("esso_canada"), + + @SerializedName("exxon") + EXXON("exxon"), + + @SerializedName("exxonmobil") + EXXONMOBIL("exxonmobil"), + + @SerializedName("family_express") + FAMILY_EXPRESS("family_express"), + + @SerializedName("fas_gas_oil") + FAS_GAS_OIL("fas_gas_oil"), + + @SerializedName("federated_coop_sonic") + FEDERATED_COOP_SONIC("federated_coop_sonic"), + + @SerializedName("fina") + FINA("fina"), + + @SerializedName("fina_inc") + FINA_INC("fina_inc"), + + @SerializedName("fkg_oil") + FKG_OIL("fkg_oil"), + + @SerializedName("flare") + FLARE("flare"), + + @SerializedName("flying_j_inc") + FLYING_J_INC("flying_j_inc"), + + @SerializedName("gas_america") + GAS_AMERICA("gas_america"), + + @SerializedName("gate_petroleum") + GATE_PETROLEUM("gate_petroleum"), + + @SerializedName("getty_petroleum") + GETTY_PETROLEUM("getty_petroleum"), + + @SerializedName("giant_eagle") + GIANT_EAGLE("giant_eagle"), + + @SerializedName("grow_mark_inc") + GROW_MARK_INC("grow_mark_inc"), + + @SerializedName("gulf") + GULF("gulf"), + + @SerializedName("gulf_canada") + GULF_CANADA("gulf_canada"), + + @SerializedName("gulf_chevron") + GULF_CHEVRON("gulf_chevron"), + + @SerializedName("handy_way_food") + HANDY_WAY_FOOD("handy_way_food"), + + @SerializedName("heron") + HERON("heron"), + + @SerializedName("holiday_stores") + HOLIDAY_STORES("holiday_stores"), + + @SerializedName("home_depot") + HOME_DEPOT("home_depot"), + + @SerializedName("husky") + HUSKY("husky"), + + @SerializedName("hyvees") + HYVEES("hyvees"), + + @SerializedName("irving") + IRVING("irving"), + + @SerializedName("irving_oil") + IRVING_OIL("irving_oil"), + + @SerializedName("j_sainsbury") + J_SAINSBURY("j_sainsbury"), + + @SerializedName("jet_conoco") + JET_CONOCO("jet_conoco"), + + @SerializedName("krogers") + KROGERS("krogers"), + + @SerializedName("kuwait") + KUWAIT("kuwait"), + + @SerializedName("kwik_trip_inc") + KWIK_TRIP_INC("kwik_trip_inc"), + + @SerializedName("lassus") + LASSUS("lassus"), + + @SerializedName("loves_country_stores") + LOVES_COUNTRY_STORES("loves_country_stores"), + + @SerializedName("mapco_express_inc") + MAPCO_EXPRESS_INC("mapco_express_inc"), + + @SerializedName("marathon_oil") + MARATHON_OIL("marathon_oil"), + + @SerializedName("martin_bailey_inc_dba_hucks") + MARTIN_BAILEY_INC_DBA_HUCKS("martin_bailey_inc_dba_hucks"), + + @SerializedName("maxol") + MAXOL("maxol"), + + @SerializedName("meineke") + MEINEKE("meineke"), + + @SerializedName("mfa") + MFA("mfa"), + + @SerializedName("mohawk") + MOHAWK("mohawk"), + + @SerializedName("mr_gas") + MR_GAS("mr_gas"), + + @SerializedName("murco") + MURCO("murco"), + + @SerializedName("murphy_oil_canada") + MURPHY_OIL_CANADA("murphy_oil_canada"), + + @SerializedName("murphy_oil_usa_inc") + MURPHY_OIL_USA_INC("murphy_oil_usa_inc"), + + @SerializedName("nexcom") + NEXCOM("nexcom"), + + @SerializedName("nordstrom_oil") + NORDSTROM_OIL("nordstrom_oil"), + + @SerializedName("olco") + OLCO("olco"), + + @SerializedName("pdq_store") + PDQ_STORE("pdq_store"), + + @SerializedName("pennzoil_products_inc") + PENNZOIL_PRODUCTS_INC("pennzoil_products_inc"), + + @SerializedName("petro") + PETRO("petro"), + + @SerializedName("petro_canada") + PETRO_CANADA("petro_canada"), + + @SerializedName("petro_t") + PETRO_T("petro_t"), + + @SerializedName("phillips") + PHILLIPS("phillips"), + + @SerializedName("pilot") + PILOT("pilot"), + + @SerializedName("pioneer") + PIONEER("pioneer"), + + @SerializedName("pure_oil") + PURE_OIL("pure_oil"), + + @SerializedName("quaker_state") + QUAKER_STATE("quaker_state"), + + @SerializedName("quarles_oil") + QUARLES_OIL("quarles_oil"), + + @SerializedName("quiktrip") + QUIKTRIP("quiktrip"), + + @SerializedName("racetrac_petroleum_inc") + RACETRAC_PETROLEUM_INC("racetrac_petroleum_inc"), + + @SerializedName("raceway_petroleum") + RACEWAY_PETROLEUM("raceway_petroleum"), + + @SerializedName("repsol") + REPSOL("repsol"), + + @SerializedName("rudy") + RUDY("rudy"), + + @SerializedName("safeway") + SAFEWAY("safeway"), + + @SerializedName("seven_eleven") + SEVEN_ELEVEN("seven_eleven"), + + @SerializedName("sheetz") + SHEETZ("sheetz"), + + @SerializedName("shell") + SHELL("shell"), + + @SerializedName("shell_canada") + SHELL_CANADA("shell_canada"), + + @SerializedName("shell_oil") + SHELL_OIL("shell_oil"), + + @SerializedName("sinclair_oil") + SINCLAIR_OIL("sinclair_oil"), + + @SerializedName("southland_oil") + SOUTHLAND_OIL("southland_oil"), + + @SerializedName("spar") + SPAR("spar"), + + @SerializedName("speedway") + SPEEDWAY("speedway"), + + @SerializedName("sun_company_inc") + SUN_COMPANY_INC("sun_company_inc"), + + @SerializedName("suncor_sunoco_canada") + SUNCOR_SUNOCO_CANADA("suncor_sunoco_canada"), + + @SerializedName("tempo") + TEMPO("tempo"), + + @SerializedName("tesco") + TESCO("tesco"), + + @SerializedName("tesoro_alaska") + TESORO_ALASKA("tesoro_alaska"), + + @SerializedName("texaco") + TEXACO("texaco"), + + @SerializedName("the_pantry_inc") + THE_PANTRY_INC("the_pantry_inc"), + + @SerializedName("thornton_oil") + THORNTON_OIL("thornton_oil"), + + @SerializedName("tosco") + TOSCO("tosco"), + + @SerializedName("total") + TOTAL("total"), + + @SerializedName("travel_centers_of_america") + TRAVEL_CENTERS_OF_AMERICA("travel_centers_of_america"), + + @SerializedName("uk") + UK("uk"), + + @SerializedName("ultramar_canada") + ULTRAMAR_CANADA("ultramar_canada"), + + @SerializedName("unbranded_or_unassigned") + UNBRANDED_OR_UNASSIGNED("unbranded_or_unassigned"), + + @SerializedName("unbranded_unassigned") + UNBRANDED_UNASSIGNED("unbranded_unassigned"), + + @SerializedName("union_76") + UNION_76("union_76"), + + @SerializedName("united_dairy_farmer") + UNITED_DAIRY_FARMER("united_dairy_farmer"), + + @SerializedName("united_refining_kwikfill") + UNITED_REFINING_KWIKFILL("united_refining_kwikfill"), + + @SerializedName("us_oil") + US_OIL("us_oil"), + + @SerializedName("usa_petroleum") + USA_PETROLEUM("usa_petroleum"), + + @SerializedName("valvoline") + VALVOLINE("valvoline"), + + @SerializedName("vg") + VG("vg"), + + @SerializedName("w_morrison") + W_MORRISON("w_morrison"), + + @SerializedName("warren_equities") + WARREN_EQUITIES("warren_equities"), + + @SerializedName("wawa") + WAWA("wawa"), + + @SerializedName("western_energetix") + WESTERN_ENERGETIX("western_energetix"), + + @SerializedName("wilco") + WILCO("wilco"), + + @SerializedName("zions") + ZIONS("zions"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Brand(String value) { + this.value = value; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Station { + /** Additional contact information for the station. */ + @SerializedName("additional_contact_info") + String additionalContactInfo; + + /** The customer service phone number of the station. */ + @SerializedName("customer_service_phone_number") + String customerServicePhoneNumber; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The partner ID code of the station. */ + @SerializedName("partner_id_code") + String partnerIdCode; + + /** The phone number of the station. */ + @SerializedName("phone_number") + String phoneNumber; + + /** The physical location of the station. */ + @SerializedName("service_location") + ServiceLocation serviceLocation; + + /** The URL of the station. */ + @SerializedName("url") + String url; + + private Station( + String additionalContactInfo, + String customerServicePhoneNumber, + Map extraParams, + String partnerIdCode, + String phoneNumber, + ServiceLocation serviceLocation, + String url) { + this.additionalContactInfo = additionalContactInfo; + this.customerServicePhoneNumber = customerServicePhoneNumber; + this.extraParams = extraParams; + this.partnerIdCode = partnerIdCode; + this.phoneNumber = phoneNumber; + this.serviceLocation = serviceLocation; + this.url = url; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String additionalContactInfo; + + private String customerServicePhoneNumber; + + private Map extraParams; + + private String partnerIdCode; + + private String phoneNumber; + + private ServiceLocation serviceLocation; + + private String url; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.FleetData.Station build() { + return new ChargeCaptureParams.PaymentDetails.FleetData.Station( + this.additionalContactInfo, + this.customerServicePhoneNumber, + this.extraParams, + this.partnerIdCode, + this.phoneNumber, + this.serviceLocation, + this.url); + } + + /** Additional contact information for the station. */ + public Builder setAdditionalContactInfo(String additionalContactInfo) { + this.additionalContactInfo = additionalContactInfo; + return this; + } + + /** The customer service phone number of the station. */ + public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.Flight.Delivery#extraParams} for the - * field documentation. + * map. See {@link ChargeCaptureParams.PaymentDetails.FleetData.Station#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -5414,8 +5793,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.Flight.Delivery#extraParams} for the - * field documentation. + * map. See {@link ChargeCaptureParams.PaymentDetails.FleetData.Station#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -5425,26 +5804,46 @@ public Builder putAllExtraParam(Map map) { return this; } - /** The delivery method for the payment. */ - public Builder setMode(ChargeCaptureParams.PaymentDetails.Flight.Delivery.Mode mode) { - this.mode = mode; + /** The partner ID code of the station. */ + public Builder setPartnerIdCode(String partnerIdCode) { + this.partnerIdCode = partnerIdCode; return this; } - /** Details of the recipient. */ - public Builder setRecipient( - ChargeCaptureParams.PaymentDetails.Flight.Delivery.Recipient recipient) { - this.recipient = recipient; + /** The phone number of the station. */ + public Builder setPhoneNumber(String phoneNumber) { + this.phoneNumber = phoneNumber; + return this; + } + + /** The physical location of the station. */ + public Builder setServiceLocation( + ChargeCaptureParams.PaymentDetails.FleetData.Station.ServiceLocation + serviceLocation) { + this.serviceLocation = serviceLocation; + return this; + } + + /** The URL of the station. */ + public Builder setUrl(String url) { + this.url = url; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Recipient { - /** The email of the recipient the ticket is delivered to. */ - @SerializedName("email") - String email; + public static class ServiceLocation { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + String city; + + /** + * Two-letter country code (ISO + * 3166-1 alpha-2). + */ + @SerializedName("country") + String country; /** * Map of extra parameters for custom features not available in this client library. The @@ -5456,20 +5855,42 @@ public static class Recipient { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** The name of the recipient the ticket is delivered to. */ - @SerializedName("name") - String name; + /** + * Required. Address line 1, such as the street, PO Box, or company name. + */ + @SerializedName("line1") + String line1; - /** The phone number of the recipient the ticket is delivered to. */ - @SerializedName("phone") - String phone; + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; - private Recipient( - String email, Map extraParams, String name, String phone) { - this.email = email; + /** ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; + + private ServiceLocation( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; this.extraParams = extraParams; - this.name = name; - this.phone = phone; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; } public static Builder builder() { @@ -5477,23 +5898,44 @@ public static Builder builder() { } public static class Builder { - private String email; + private String city; + + private String country; private Map extraParams; - private String name; + private String line1; - private String phone; + private String line2; + + private String postalCode; + + private String state; /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.Flight.Delivery.Recipient build() { - return new ChargeCaptureParams.PaymentDetails.Flight.Delivery.Recipient( - this.email, this.extraParams, this.name, this.phone); + public ChargeCaptureParams.PaymentDetails.FleetData.Station.ServiceLocation build() { + return new ChargeCaptureParams.PaymentDetails.FleetData.Station.ServiceLocation( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); } - /** The email of the recipient the ticket is delivered to. */ - public Builder setEmail(String email) { - this.email = email; + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; return this; } @@ -5501,8 +5943,8 @@ public Builder setEmail(String email) { * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeCaptureParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for the - * field documentation. + * ChargeCaptureParams.PaymentDetails.FleetData.Station.ServiceLocation#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -5516,8 +5958,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeCaptureParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for the - * field documentation. + * ChargeCaptureParams.PaymentDetails.FleetData.Station.ServiceLocation#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -5527,45 +5969,42 @@ public Builder putAllExtraParam(Map map) { return this; } - /** The name of the recipient the ticket is delivered to. */ - public Builder setName(String name) { - this.name = name; + /** + * Required. Address line 1, such as the street, PO Box, or company + * name. + */ + public Builder setLine1(String line1) { + this.line1 = line1; return this; } - /** The phone number of the recipient the ticket is delivered to. */ - public Builder setPhone(String phone) { - this.phone = phone; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; return this; } - } - } - - public enum Mode implements ApiRequestParams.EnumParam { - @SerializedName("email") - EMAIL("email"), - - @SerializedName("phone") - PHONE("phone"), - - @SerializedName("pickup") - PICKUP("pickup"), - @SerializedName("post") - POST("post"); - - @Getter(onMethod_ = {@Override}) - private final String value; + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - Mode(String value) { - this.value = value; + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Passenger { + public static class Vat { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -5577,14 +6016,15 @@ public static class Passenger { Map extraParams; /** - * Required. Full name of the person or entity on the flight reservation. + * Required. Indicates the merchant's agreement for Invoice on Behalf (IOB) + * VAT processing. */ - @SerializedName("name") - String name; + @SerializedName("iob_indicator") + IobIndicator iobIndicator; - private Passenger(Map extraParams, String name) { + private Vat(Map extraParams, IobIndicator iobIndicator) { this.extraParams = extraParams; - this.name = name; + this.iobIndicator = iobIndicator; } public static Builder builder() { @@ -5594,19 +6034,19 @@ public static Builder builder() { public static class Builder { private Map extraParams; - private String name; + private IobIndicator iobIndicator; /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.Flight.Passenger build() { - return new ChargeCaptureParams.PaymentDetails.Flight.Passenger( - this.extraParams, this.name); + public ChargeCaptureParams.PaymentDetails.FleetData.Vat build() { + return new ChargeCaptureParams.PaymentDetails.FleetData.Vat( + this.extraParams, this.iobIndicator); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.Flight.Passenger#extraParams} for - * the field documentation. + * map. See {@link ChargeCaptureParams.PaymentDetails.FleetData.Vat#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -5619,8 +6059,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.Flight.Passenger#extraParams} for - * the field documentation. + * map. See {@link ChargeCaptureParams.PaymentDetails.FleetData.Vat#extraParams} for the + * field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -5631,182 +6071,312 @@ public Builder putAllExtraParam(Map map) { } /** - * Required. Full name of the person or entity on the flight reservation. + * Required. Indicates the merchant's agreement for Invoice on Behalf + * (IOB) VAT processing. */ - public Builder setName(String name) { - this.name = name; + public Builder setIobIndicator( + ChargeCaptureParams.PaymentDetails.FleetData.Vat.IobIndicator iobIndicator) { + this.iobIndicator = iobIndicator; return this; } } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Segment { - /** The flight segment amount. */ - @SerializedName("amount") - Long amount; + public enum IobIndicator implements ApiRequestParams.EnumParam { + @SerializedName("issuer_to_iob") + ISSUER_TO_IOB("issuer_to_iob"), - /** - * The International Air Transport Association (IATA) airport code for the arrival airport. - */ - @SerializedName("arrival_airport") - String arrivalAirport; + @SerializedName("issuer_to_iob_and_incremental_certification") + ISSUER_TO_IOB_AND_INCREMENTAL_CERTIFICATION( + "issuer_to_iob_and_incremental_certification"), - /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ - @SerializedName("arrives_at") - Long arrivesAt; + @SerializedName("merchant_does_not_agree_to_iob") + MERCHANT_DOES_NOT_AGREE_TO_IOB("merchant_does_not_agree_to_iob"); - /** - * The International Air Transport Association (IATA) carrier code of the carrier operating - * the flight segment. - */ - @SerializedName("carrier") - String carrier; + @Getter(onMethod_ = {@Override}) + private final String value; - /** - * Required. The departure time for the flight segment. Measured in seconds - * since the Unix epoch. - */ - @SerializedName("departs_at") - Long departsAt; + IobIndicator(String value) { + this.value = value; + } + } + } + } - /** - * The International Air Transport Association (IATA) airport code for the departure - * airport. - */ - @SerializedName("departure_airport") - String departureAirport; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Flight { + /** Affiliate details for this purchase. */ + @SerializedName("affiliate") + Affiliate affiliate; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** + * The agency number (i.e. International Air Transport Association (IATA) agency number) of + * the travel agency that made the booking. + */ + @SerializedName("agency_number") + String agencyNumber; - /** The flight number associated with the segment. */ - @SerializedName("flight_number") - String flightNumber; + /** + * The International Air Transport Association (IATA) carrier code of the carrier that issued + * the ticket. + */ + @SerializedName("carrier") + String carrier; - /** The fare class for the segment. */ - @SerializedName("service_class") - ServiceClass serviceClass; + /** Delivery details for this purchase. */ + @SerializedName("delivery") + Delivery delivery; - private Segment( - Long amount, - String arrivalAirport, - Long arrivesAt, - String carrier, - Long departsAt, - String departureAirport, - Map extraParams, - String flightNumber, - ServiceClass serviceClass) { - this.amount = amount; - this.arrivalAirport = arrivalAirport; - this.arrivesAt = arrivesAt; - this.carrier = carrier; - this.departsAt = departsAt; - this.departureAirport = departureAirport; - this.extraParams = extraParams; - this.flightNumber = flightNumber; - this.serviceClass = serviceClass; - } + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - public static Builder builder() { - return new Builder(); - } + /** The name of the person or entity on the reservation. */ + @SerializedName("passenger_name") + String passengerName; - public static class Builder { - private Long amount; + /** The details of the passengers in the travel reservation. */ + @SerializedName("passengers") + List passengers; - private String arrivalAirport; + /** Required. The individual flight segments associated with the trip. */ + @SerializedName("segments") + List segments; - private Long arrivesAt; + /** The ticket number associated with the travel reservation. */ + @SerializedName("ticket_number") + String ticketNumber; - private String carrier; + private Flight( + Affiliate affiliate, + String agencyNumber, + String carrier, + Delivery delivery, + Map extraParams, + String passengerName, + List passengers, + List segments, + String ticketNumber) { + this.affiliate = affiliate; + this.agencyNumber = agencyNumber; + this.carrier = carrier; + this.delivery = delivery; + this.extraParams = extraParams; + this.passengerName = passengerName; + this.passengers = passengers; + this.segments = segments; + this.ticketNumber = ticketNumber; + } - private Long departsAt; + public static Builder builder() { + return new Builder(); + } - private String departureAirport; + public static class Builder { + private Affiliate affiliate; - private Map extraParams; + private String agencyNumber; - private String flightNumber; + private String carrier; - private ServiceClass serviceClass; + private Delivery delivery; - /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.Flight.Segment build() { - return new ChargeCaptureParams.PaymentDetails.Flight.Segment( - this.amount, - this.arrivalAirport, - this.arrivesAt, - this.carrier, - this.departsAt, - this.departureAirport, - this.extraParams, - this.flightNumber, - this.serviceClass); + private Map extraParams; + + private String passengerName; + + private List passengers; + + private List segments; + + private String ticketNumber; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.Flight build() { + return new ChargeCaptureParams.PaymentDetails.Flight( + this.affiliate, + this.agencyNumber, + this.carrier, + this.delivery, + this.extraParams, + this.passengerName, + this.passengers, + this.segments, + this.ticketNumber); + } + + /** Affiliate details for this purchase. */ + public Builder setAffiliate(ChargeCaptureParams.PaymentDetails.Flight.Affiliate affiliate) { + this.affiliate = affiliate; + return this; + } + + /** + * The agency number (i.e. International Air Transport Association (IATA) agency number) of + * the travel agency that made the booking. + */ + public Builder setAgencyNumber(String agencyNumber) { + this.agencyNumber = agencyNumber; + return this; + } + + /** + * The International Air Transport Association (IATA) carrier code of the carrier that + * issued the ticket. + */ + public Builder setCarrier(String carrier) { + this.carrier = carrier; + return this; + } + + /** Delivery details for this purchase. */ + public Builder setDelivery(ChargeCaptureParams.PaymentDetails.Flight.Delivery delivery) { + this.delivery = delivery; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.Flight#extraParams} for the field + * documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.put(key, value); + return this; + } - /** The flight segment amount. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.Flight#extraParams} for the field + * documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.putAll(map); + return this; + } - /** - * The International Air Transport Association (IATA) airport code for the arrival - * airport. - */ - public Builder setArrivalAirport(String arrivalAirport) { - this.arrivalAirport = arrivalAirport; - return this; + /** The name of the person or entity on the reservation. */ + public Builder setPassengerName(String passengerName) { + this.passengerName = passengerName; + return this; + } + + /** + * Add an element to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeCaptureParams.PaymentDetails.Flight#passengers} for the field documentation. + */ + public Builder addPassenger(ChargeCaptureParams.PaymentDetails.Flight.Passenger element) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); } + this.passengers.add(element); + return this; + } - /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ - public Builder setArrivesAt(Long arrivesAt) { - this.arrivesAt = arrivesAt; - return this; + /** + * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeCaptureParams.PaymentDetails.Flight#passengers} for the field documentation. + */ + public Builder addAllPassenger( + List elements) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); } + this.passengers.addAll(elements); + return this; + } - /** - * The International Air Transport Association (IATA) carrier code of the carrier - * operating the flight segment. - */ - public Builder setCarrier(String carrier) { - this.carrier = carrier; - return this; + /** + * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * ChargeCaptureParams.PaymentDetails.Flight#segments} for the field documentation. + */ + public Builder addSegment(ChargeCaptureParams.PaymentDetails.Flight.Segment element) { + if (this.segments == null) { + this.segments = new ArrayList<>(); } + this.segments.add(element); + return this; + } - /** - * Required. The departure time for the flight segment. Measured in - * seconds since the Unix epoch. - */ - public Builder setDepartsAt(Long departsAt) { - this.departsAt = departsAt; - return this; + /** + * Add all elements to `segments` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeCaptureParams.PaymentDetails.Flight#segments} for the field documentation. + */ + public Builder addAllSegment( + List elements) { + if (this.segments == null) { + this.segments = new ArrayList<>(); } + this.segments.addAll(elements); + return this; + } - /** - * The International Air Transport Association (IATA) airport code for the departure - * airport. - */ - public Builder setDepartureAirport(String departureAirport) { - this.departureAirport = departureAirport; - return this; + /** The ticket number associated with the travel reservation. */ + public Builder setTicketNumber(String ticketNumber) { + this.ticketNumber = ticketNumber; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Affiliate { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Required. The name of the affiliate that originated the purchase. */ + @SerializedName("name") + String name; + + private Affiliate(Map extraParams, String name) { + this.extraParams = extraParams; + this.name = name; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String name; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.Flight.Affiliate build() { + return new ChargeCaptureParams.PaymentDetails.Flight.Affiliate( + this.extraParams, this.name); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.Flight.Segment#extraParams} for the - * field documentation. + * map. See {@link ChargeCaptureParams.PaymentDetails.Flight.Affiliate#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -5819,8 +6389,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.Flight.Segment#extraParams} for the - * field documentation. + * map. See {@link ChargeCaptureParams.PaymentDetails.Flight.Affiliate#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -5830,31 +6400,516 @@ public Builder putAllExtraParam(Map map) { return this; } - /** The flight number associated with the segment. */ - public Builder setFlightNumber(String flightNumber) { - this.flightNumber = flightNumber; - return this; - } - - /** The fare class for the segment. */ - public Builder setServiceClass( - ChargeCaptureParams.PaymentDetails.Flight.Segment.ServiceClass serviceClass) { - this.serviceClass = serviceClass; + /** Required. The name of the affiliate that originated the purchase. */ + public Builder setName(String name) { + this.name = name; return this; } } + } - public enum ServiceClass implements ApiRequestParams.EnumParam { - @SerializedName("business") - BUSINESS("business"), - - @SerializedName("economy") - ECONOMY("economy"), - - @SerializedName("first") - FIRST("first"), - - @SerializedName("premium_economy") + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Delivery { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The delivery method for the payment. */ + @SerializedName("mode") + Mode mode; + + /** Details of the recipient. */ + @SerializedName("recipient") + Recipient recipient; + + private Delivery(Map extraParams, Mode mode, Recipient recipient) { + this.extraParams = extraParams; + this.mode = mode; + this.recipient = recipient; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Mode mode; + + private Recipient recipient; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.Flight.Delivery build() { + return new ChargeCaptureParams.PaymentDetails.Flight.Delivery( + this.extraParams, this.mode, this.recipient); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.Flight.Delivery#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.Flight.Delivery#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The delivery method for the payment. */ + public Builder setMode(ChargeCaptureParams.PaymentDetails.Flight.Delivery.Mode mode) { + this.mode = mode; + return this; + } + + /** Details of the recipient. */ + public Builder setRecipient( + ChargeCaptureParams.PaymentDetails.Flight.Delivery.Recipient recipient) { + this.recipient = recipient; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Recipient { + /** The email of the recipient the ticket is delivered to. */ + @SerializedName("email") + String email; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The name of the recipient the ticket is delivered to. */ + @SerializedName("name") + String name; + + /** The phone number of the recipient the ticket is delivered to. */ + @SerializedName("phone") + String phone; + + private Recipient( + String email, Map extraParams, String name, String phone) { + this.email = email; + this.extraParams = extraParams; + this.name = name; + this.phone = phone; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String email; + + private Map extraParams; + + private String name; + + private String phone; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.Flight.Delivery.Recipient build() { + return new ChargeCaptureParams.PaymentDetails.Flight.Delivery.Recipient( + this.email, this.extraParams, this.name, this.phone); + } + + /** The email of the recipient the ticket is delivered to. */ + public Builder setEmail(String email) { + this.email = email; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The name of the recipient the ticket is delivered to. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** The phone number of the recipient the ticket is delivered to. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } + } + } + + public enum Mode implements ApiRequestParams.EnumParam { + @SerializedName("email") + EMAIL("email"), + + @SerializedName("phone") + PHONE("phone"), + + @SerializedName("pickup") + PICKUP("pickup"), + + @SerializedName("post") + POST("post"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Mode(String value) { + this.value = value; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Passenger { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** + * Required. Full name of the person or entity on the flight reservation. + */ + @SerializedName("name") + String name; + + private Passenger(Map extraParams, String name) { + this.extraParams = extraParams; + this.name = name; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String name; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.Flight.Passenger build() { + return new ChargeCaptureParams.PaymentDetails.Flight.Passenger( + this.extraParams, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.Flight.Passenger#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.Flight.Passenger#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. Full name of the person or entity on the flight reservation. + */ + public Builder setName(String name) { + this.name = name; + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Segment { + /** The flight segment amount. */ + @SerializedName("amount") + Long amount; + + /** + * The International Air Transport Association (IATA) airport code for the arrival airport. + */ + @SerializedName("arrival_airport") + String arrivalAirport; + + /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ + @SerializedName("arrives_at") + Long arrivesAt; + + /** + * The International Air Transport Association (IATA) carrier code of the carrier operating + * the flight segment. + */ + @SerializedName("carrier") + String carrier; + + /** + * Required. The departure time for the flight segment. Measured in seconds + * since the Unix epoch. + */ + @SerializedName("departs_at") + Long departsAt; + + /** + * The International Air Transport Association (IATA) airport code for the departure + * airport. + */ + @SerializedName("departure_airport") + String departureAirport; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The flight number associated with the segment. */ + @SerializedName("flight_number") + String flightNumber; + + /** The fare class for the segment. */ + @SerializedName("service_class") + ServiceClass serviceClass; + + private Segment( + Long amount, + String arrivalAirport, + Long arrivesAt, + String carrier, + Long departsAt, + String departureAirport, + Map extraParams, + String flightNumber, + ServiceClass serviceClass) { + this.amount = amount; + this.arrivalAirport = arrivalAirport; + this.arrivesAt = arrivesAt; + this.carrier = carrier; + this.departsAt = departsAt; + this.departureAirport = departureAirport; + this.extraParams = extraParams; + this.flightNumber = flightNumber; + this.serviceClass = serviceClass; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private String arrivalAirport; + + private Long arrivesAt; + + private String carrier; + + private Long departsAt; + + private String departureAirport; + + private Map extraParams; + + private String flightNumber; + + private ServiceClass serviceClass; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.Flight.Segment build() { + return new ChargeCaptureParams.PaymentDetails.Flight.Segment( + this.amount, + this.arrivalAirport, + this.arrivesAt, + this.carrier, + this.departsAt, + this.departureAirport, + this.extraParams, + this.flightNumber, + this.serviceClass); + } + + /** The flight segment amount. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** + * The International Air Transport Association (IATA) airport code for the arrival + * airport. + */ + public Builder setArrivalAirport(String arrivalAirport) { + this.arrivalAirport = arrivalAirport; + return this; + } + + /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ + public Builder setArrivesAt(Long arrivesAt) { + this.arrivesAt = arrivesAt; + return this; + } + + /** + * The International Air Transport Association (IATA) carrier code of the carrier + * operating the flight segment. + */ + public Builder setCarrier(String carrier) { + this.carrier = carrier; + return this; + } + + /** + * Required. The departure time for the flight segment. Measured in + * seconds since the Unix epoch. + */ + public Builder setDepartsAt(Long departsAt) { + this.departsAt = departsAt; + return this; + } + + /** + * The International Air Transport Association (IATA) airport code for the departure + * airport. + */ + public Builder setDepartureAirport(String departureAirport) { + this.departureAirport = departureAirport; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.Flight.Segment#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.Flight.Segment#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The flight number associated with the segment. */ + public Builder setFlightNumber(String flightNumber) { + this.flightNumber = flightNumber; + return this; + } + + /** The fare class for the segment. */ + public Builder setServiceClass( + ChargeCaptureParams.PaymentDetails.Flight.Segment.ServiceClass serviceClass) { + this.serviceClass = serviceClass; + return this; + } + } + + public enum ServiceClass implements ApiRequestParams.EnumParam { + @SerializedName("business") + BUSINESS("business"), + + @SerializedName("economy") + ECONOMY("economy"), + + @SerializedName("first") + FIRST("first"), + + @SerializedName("premium_economy") PREMIUM_ECONOMY("premium_economy"); @Getter(onMethod_ = {@Override}) @@ -8285,17 +9340,227 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Required. The name of the affiliate that originated the purchase. */ - public Builder setName(String name) { - this.name = name; - return this; + /** Required. The name of the affiliate that originated the purchase. */ + public Builder setName(String name) { + this.name = name; + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Delivery { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The delivery method for the payment. */ + @SerializedName("mode") + Mode mode; + + /** Details of the recipient. */ + @SerializedName("recipient") + Recipient recipient; + + private Delivery(Map extraParams, Mode mode, Recipient recipient) { + this.extraParams = extraParams; + this.mode = mode; + this.recipient = recipient; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Mode mode; + + private Recipient recipient; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.Lodging.Delivery build() { + return new ChargeCaptureParams.PaymentDetails.Lodging.Delivery( + this.extraParams, this.mode, this.recipient); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.Lodging.Delivery#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.Lodging.Delivery#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The delivery method for the payment. */ + public Builder setMode(ChargeCaptureParams.PaymentDetails.Lodging.Delivery.Mode mode) { + this.mode = mode; + return this; + } + + /** Details of the recipient. */ + public Builder setRecipient( + ChargeCaptureParams.PaymentDetails.Lodging.Delivery.Recipient recipient) { + this.recipient = recipient; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Recipient { + /** The email of the recipient the ticket is delivered to. */ + @SerializedName("email") + String email; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The name of the recipient the ticket is delivered to. */ + @SerializedName("name") + String name; + + /** The phone number of the recipient the ticket is delivered to. */ + @SerializedName("phone") + String phone; + + private Recipient( + String email, Map extraParams, String name, String phone) { + this.email = email; + this.extraParams = extraParams; + this.name = name; + this.phone = phone; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String email; + + private Map extraParams; + + private String name; + + private String phone; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.Lodging.Delivery.Recipient build() { + return new ChargeCaptureParams.PaymentDetails.Lodging.Delivery.Recipient( + this.email, this.extraParams, this.name, this.phone); + } + + /** The email of the recipient the ticket is delivered to. */ + public Builder setEmail(String email) { + this.email = email; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The name of the recipient the ticket is delivered to. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** The phone number of the recipient the ticket is delivered to. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } + } + } + + public enum Mode implements ApiRequestParams.EnumParam { + @SerializedName("email") + EMAIL("email"), + + @SerializedName("phone") + PHONE("phone"), + + @SerializedName("pickup") + PICKUP("pickup"), + + @SerializedName("post") + POST("post"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Mode(String value) { + this.value = value; } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Delivery { + public static class Passenger { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -8306,18 +9571,15 @@ public static class Delivery { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** The delivery method for the payment. */ - @SerializedName("mode") - Mode mode; - - /** Details of the recipient. */ - @SerializedName("recipient") - Recipient recipient; + /** + * Required. Full name of the person or entity on the lodging reservation. + */ + @SerializedName("name") + String name; - private Delivery(Map extraParams, Mode mode, Recipient recipient) { + private Passenger(Map extraParams, String name) { this.extraParams = extraParams; - this.mode = mode; - this.recipient = recipient; + this.name = name; } public static Builder builder() { @@ -8327,20 +9589,18 @@ public static Builder builder() { public static class Builder { private Map extraParams; - private Mode mode; - - private Recipient recipient; + private String name; /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.Lodging.Delivery build() { - return new ChargeCaptureParams.PaymentDetails.Lodging.Delivery( - this.extraParams, this.mode, this.recipient); + public ChargeCaptureParams.PaymentDetails.Lodging.Passenger build() { + return new ChargeCaptureParams.PaymentDetails.Lodging.Passenger( + this.extraParams, this.name); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.Lodging.Delivery#extraParams} for + * map. See {@link ChargeCaptureParams.PaymentDetails.Lodging.Passenger#extraParams} for * the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -8354,7 +9614,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.Lodging.Delivery#extraParams} for + * map. See {@link ChargeCaptureParams.PaymentDetails.Lodging.Passenger#extraParams} for * the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -8365,594 +9625,747 @@ public Builder putAllExtraParam(Map map) { return this; } - /** The delivery method for the payment. */ - public Builder setMode(ChargeCaptureParams.PaymentDetails.Lodging.Delivery.Mode mode) { - this.mode = mode; + /** + * Required. Full name of the person or entity on the lodging + * reservation. + */ + public Builder setName(String name) { + this.name = name; return this; } + } + } - /** Details of the recipient. */ - public Builder setRecipient( - ChargeCaptureParams.PaymentDetails.Lodging.Delivery.Recipient recipient) { - this.recipient = recipient; - return this; - } + public enum Category implements ApiRequestParams.EnumParam { + @SerializedName("hotel") + HOTEL("hotel"), + + @SerializedName("vacation_rental") + VACATION_RENTAL("vacation_rental"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Category(String value) { + this.value = value; } + } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Recipient { - /** The email of the recipient the ticket is delivered to. */ - @SerializedName("email") - String email; + public enum ExtraCharge implements ApiRequestParams.EnumParam { + @SerializedName("gift_shop") + GIFT_SHOP("gift_shop"), - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + @SerializedName("laundry") + LAUNDRY("laundry"), - /** The name of the recipient the ticket is delivered to. */ - @SerializedName("name") - String name; + @SerializedName("mini_bar") + MINI_BAR("mini_bar"), - /** The phone number of the recipient the ticket is delivered to. */ - @SerializedName("phone") - String phone; + @SerializedName("other") + OTHER("other"), - private Recipient( - String email, Map extraParams, String name, String phone) { - this.email = email; - this.extraParams = extraParams; - this.name = name; - this.phone = phone; - } + @SerializedName("restaurant") + RESTAURANT("restaurant"), - public static Builder builder() { - return new Builder(); - } + @SerializedName("telephone") + TELEPHONE("telephone"); - public static class Builder { - private String email; + @Getter(onMethod_ = {@Override}) + private final String value; - private Map extraParams; + ExtraCharge(String value) { + this.value = value; + } + } + } - private String name; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class LodgingData { + /** Accommodation details for the lodging. */ + @SerializedName("accommodation") + Accommodation accommodation; - private String phone; + /** Affiliate details if applicable. */ + @SerializedName("affiliate") + Affiliate affiliate; + + /** Booking confirmation number for the lodging. */ + @SerializedName("booking_number") + String bookingNumber; + + /** Required. Check-in date. */ + @SerializedName("checkin_at") + Long checkinAt; + + /** Required. Check-out date. */ + @SerializedName("checkout_at") + Long checkoutAt; + + /** Customer service phone number for the lodging company. */ + @SerializedName("customer_service_phone_number") + String customerServicePhoneNumber; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Whether the lodging is compliant with any hotel fire safety regulations. */ + @SerializedName("fire_safety_act_compliance_indicator") + Boolean fireSafetyActComplianceIndicator; + + /** List of guests for the lodging. */ + @SerializedName("guests") + List guests; + + /** Host details for the lodging. */ + @SerializedName("host") + Host host; + + /** List of insurances for the lodging. */ + @SerializedName("insurances") + List insurances; + + /** Whether the renter is a no-show. */ + @SerializedName("no_show_indicator") + Boolean noShowIndicator; + + /** Renter ID number for the lodging. */ + @SerializedName("renter_id_number") + String renterIdNumber; + + /** Renter name for the lodging. */ + @SerializedName("renter_name") + String renterName; + + /** Required. Total details for the lodging. */ + @SerializedName("total") + Total total; + + private LodgingData( + Accommodation accommodation, + Affiliate affiliate, + String bookingNumber, + Long checkinAt, + Long checkoutAt, + String customerServicePhoneNumber, + Map extraParams, + Boolean fireSafetyActComplianceIndicator, + List guests, + Host host, + List insurances, + Boolean noShowIndicator, + String renterIdNumber, + String renterName, + Total total) { + this.accommodation = accommodation; + this.affiliate = affiliate; + this.bookingNumber = bookingNumber; + this.checkinAt = checkinAt; + this.checkoutAt = checkoutAt; + this.customerServicePhoneNumber = customerServicePhoneNumber; + this.extraParams = extraParams; + this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; + this.guests = guests; + this.host = host; + this.insurances = insurances; + this.noShowIndicator = noShowIndicator; + this.renterIdNumber = renterIdNumber; + this.renterName = renterName; + this.total = total; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Accommodation accommodation; + + private Affiliate affiliate; + + private String bookingNumber; + + private Long checkinAt; + + private Long checkoutAt; + + private String customerServicePhoneNumber; + + private Map extraParams; + + private Boolean fireSafetyActComplianceIndicator; + + private List guests; + + private Host host; - /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.Lodging.Delivery.Recipient build() { - return new ChargeCaptureParams.PaymentDetails.Lodging.Delivery.Recipient( - this.email, this.extraParams, this.name, this.phone); - } + private List insurances; - /** The email of the recipient the ticket is delivered to. */ - public Builder setEmail(String email) { - this.email = email; - return this; - } + private Boolean noShowIndicator; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeCaptureParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + private String renterIdNumber; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeCaptureParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + private String renterName; - /** The name of the recipient the ticket is delivered to. */ - public Builder setName(String name) { - this.name = name; - return this; - } + private Total total; - /** The phone number of the recipient the ticket is delivered to. */ - public Builder setPhone(String phone) { - this.phone = phone; - return this; - } - } + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.LodgingData build() { + return new ChargeCaptureParams.PaymentDetails.LodgingData( + this.accommodation, + this.affiliate, + this.bookingNumber, + this.checkinAt, + this.checkoutAt, + this.customerServicePhoneNumber, + this.extraParams, + this.fireSafetyActComplianceIndicator, + this.guests, + this.host, + this.insurances, + this.noShowIndicator, + this.renterIdNumber, + this.renterName, + this.total); } - public enum Mode implements ApiRequestParams.EnumParam { - @SerializedName("email") - EMAIL("email"), + /** Accommodation details for the lodging. */ + public Builder setAccommodation( + ChargeCaptureParams.PaymentDetails.LodgingData.Accommodation accommodation) { + this.accommodation = accommodation; + return this; + } - @SerializedName("phone") - PHONE("phone"), + /** Affiliate details if applicable. */ + public Builder setAffiliate( + ChargeCaptureParams.PaymentDetails.LodgingData.Affiliate affiliate) { + this.affiliate = affiliate; + return this; + } - @SerializedName("pickup") - PICKUP("pickup"), + /** Booking confirmation number for the lodging. */ + public Builder setBookingNumber(String bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } - @SerializedName("post") - POST("post"); + /** Required. Check-in date. */ + public Builder setCheckinAt(Long checkinAt) { + this.checkinAt = checkinAt; + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** Required. Check-out date. */ + public Builder setCheckoutAt(Long checkoutAt) { + this.checkoutAt = checkoutAt; + return this; + } - Mode(String value) { - this.value = value; - } + /** Customer service phone number for the lodging company. */ + public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Passenger { /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData#extraParams} for the field + * documentation. */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } /** - * Required. Full name of the person or entity on the lodging reservation. + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData#extraParams} for the field + * documentation. */ - @SerializedName("name") - String name; - - private Passenger(Map extraParams, String name) { - this.extraParams = extraParams; - this.name = name; + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; } - public static Builder builder() { - return new Builder(); + /** Whether the lodging is compliant with any hotel fire safety regulations. */ + public Builder setFireSafetyActComplianceIndicator( + Boolean fireSafetyActComplianceIndicator) { + this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; + return this; } - public static class Builder { - private Map extraParams; - - private String name; - - /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.Lodging.Passenger build() { - return new ChargeCaptureParams.PaymentDetails.Lodging.Passenger( - this.extraParams, this.name); + /** + * Add an element to `guests` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData#guests} for the field documentation. + */ + public Builder addGuest(ChargeCaptureParams.PaymentDetails.LodgingData.Guest element) { + if (this.guests == null) { + this.guests = new ArrayList<>(); } + this.guests.add(element); + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.Lodging.Passenger#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; + /** + * Add all elements to `guests` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData#guests} for the field documentation. + */ + public Builder addAllGuest( + List elements) { + if (this.guests == null) { + this.guests = new ArrayList<>(); } + this.guests.addAll(elements); + return this; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.Lodging.Passenger#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; + /** Host details for the lodging. */ + public Builder setHost(ChargeCaptureParams.PaymentDetails.LodgingData.Host host) { + this.host = host; + return this; + } + + /** + * Add an element to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData#insurances} for the field documentation. + */ + public Builder addInsurance( + ChargeCaptureParams.PaymentDetails.LodgingData.Insurance element) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); } + this.insurances.add(element); + return this; + } - /** - * Required. Full name of the person or entity on the lodging - * reservation. - */ - public Builder setName(String name) { - this.name = name; - return this; + /** + * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData#insurances} for the field documentation. + */ + public Builder addAllInsurance( + List elements) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); } + this.insurances.addAll(elements); + return this; } - } - public enum Category implements ApiRequestParams.EnumParam { - @SerializedName("hotel") - HOTEL("hotel"), + /** Whether the renter is a no-show. */ + public Builder setNoShowIndicator(Boolean noShowIndicator) { + this.noShowIndicator = noShowIndicator; + return this; + } - @SerializedName("vacation_rental") - VACATION_RENTAL("vacation_rental"); + /** Renter ID number for the lodging. */ + public Builder setRenterIdNumber(String renterIdNumber) { + this.renterIdNumber = renterIdNumber; + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** Renter name for the lodging. */ + public Builder setRenterName(String renterName) { + this.renterName = renterName; + return this; + } - Category(String value) { - this.value = value; + /** Required. Total details for the lodging. */ + public Builder setTotal(ChargeCaptureParams.PaymentDetails.LodgingData.Total total) { + this.total = total; + return this; } } - public enum ExtraCharge implements ApiRequestParams.EnumParam { - @SerializedName("gift_shop") - GIFT_SHOP("gift_shop"), - - @SerializedName("laundry") - LAUNDRY("laundry"), - - @SerializedName("mini_bar") - MINI_BAR("mini_bar"), - - @SerializedName("other") - OTHER("other"), - - @SerializedName("restaurant") - RESTAURANT("restaurant"), + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Accommodation { + /** Type of accommodation. */ + @SerializedName("accommodation_type") + AccommodationType accommodationType; - @SerializedName("telephone") - TELEPHONE("telephone"); + /** Bed type. */ + @SerializedName("bed_type") + String bedType; - @Getter(onMethod_ = {@Override}) - private final String value; + /** Daily accommodation rate in cents. */ + @SerializedName("daily_rate_amount") + Long dailyRateAmount; - ExtraCharge(String value) { - this.value = value; - } - } - } + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class LodgingData { - /** Accommodation details for the lodging. */ - @SerializedName("accommodation") - Accommodation accommodation; + /** Number of nights. */ + @SerializedName("nights") + Long nights; - /** Affiliate details if applicable. */ - @SerializedName("affiliate") - Affiliate affiliate; + /** Number of rooms, cabanas, apartments, and so on. */ + @SerializedName("number_of_rooms") + Long numberOfRooms; - /** Booking confirmation number for the lodging. */ - @SerializedName("booking_number") - String bookingNumber; + /** Rate type. */ + @SerializedName("rate_type") + String rateType; - /** Required. Check-in date. */ - @SerializedName("checkin_at") - Long checkinAt; + /** Whether smoking is allowed. */ + @SerializedName("smoking_indicator") + Boolean smokingIndicator; - /** Required. Check-out date. */ - @SerializedName("checkout_at") - Long checkoutAt; + private Accommodation( + AccommodationType accommodationType, + String bedType, + Long dailyRateAmount, + Map extraParams, + Long nights, + Long numberOfRooms, + String rateType, + Boolean smokingIndicator) { + this.accommodationType = accommodationType; + this.bedType = bedType; + this.dailyRateAmount = dailyRateAmount; + this.extraParams = extraParams; + this.nights = nights; + this.numberOfRooms = numberOfRooms; + this.rateType = rateType; + this.smokingIndicator = smokingIndicator; + } - /** Customer service phone number for the lodging company. */ - @SerializedName("customer_service_phone_number") - String customerServicePhoneNumber; + public static Builder builder() { + return new Builder(); + } - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) - * name in this param object. Effectively, this map is flattened to its parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public static class Builder { + private AccommodationType accommodationType; - /** Whether the lodging is compliant with any hotel fire safety regulations. */ - @SerializedName("fire_safety_act_compliance_indicator") - Boolean fireSafetyActComplianceIndicator; + private String bedType; - /** List of guests for the lodging. */ - @SerializedName("guests") - List guests; + private Long dailyRateAmount; - /** Host details for the lodging. */ - @SerializedName("host") - Host host; + private Map extraParams; - /** List of insurances for the lodging. */ - @SerializedName("insurances") - List insurances; + private Long nights; - /** Whether the renter is a no-show. */ - @SerializedName("no_show_indicator") - Boolean noShowIndicator; + private Long numberOfRooms; - /** Renter ID number for the lodging. */ - @SerializedName("renter_id_number") - String renterIdNumber; + private String rateType; - /** Renter name for the lodging. */ - @SerializedName("renter_name") - String renterName; + private Boolean smokingIndicator; - /** Required. Total details for the lodging. */ - @SerializedName("total") - Total total; + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.LodgingData.Accommodation build() { + return new ChargeCaptureParams.PaymentDetails.LodgingData.Accommodation( + this.accommodationType, + this.bedType, + this.dailyRateAmount, + this.extraParams, + this.nights, + this.numberOfRooms, + this.rateType, + this.smokingIndicator); + } - private LodgingData( - Accommodation accommodation, - Affiliate affiliate, - String bookingNumber, - Long checkinAt, - Long checkoutAt, - String customerServicePhoneNumber, - Map extraParams, - Boolean fireSafetyActComplianceIndicator, - List guests, - Host host, - List insurances, - Boolean noShowIndicator, - String renterIdNumber, - String renterName, - Total total) { - this.accommodation = accommodation; - this.affiliate = affiliate; - this.bookingNumber = bookingNumber; - this.checkinAt = checkinAt; - this.checkoutAt = checkoutAt; - this.customerServicePhoneNumber = customerServicePhoneNumber; - this.extraParams = extraParams; - this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; - this.guests = guests; - this.host = host; - this.insurances = insurances; - this.noShowIndicator = noShowIndicator; - this.renterIdNumber = renterIdNumber; - this.renterName = renterName; - this.total = total; - } + /** Type of accommodation. */ + public Builder setAccommodationType( + ChargeCaptureParams.PaymentDetails.LodgingData.Accommodation.AccommodationType + accommodationType) { + this.accommodationType = accommodationType; + return this; + } - public static Builder builder() { - return new Builder(); - } + /** Bed type. */ + public Builder setBedType(String bedType) { + this.bedType = bedType; + return this; + } - public static class Builder { - private Accommodation accommodation; + /** Daily accommodation rate in cents. */ + public Builder setDailyRateAmount(Long dailyRateAmount) { + this.dailyRateAmount = dailyRateAmount; + return this; + } - private Affiliate affiliate; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData.Accommodation#extraParams} for the field + * documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - private String bookingNumber; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData.Accommodation#extraParams} for the field + * documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - private Long checkinAt; + /** Number of nights. */ + public Builder setNights(Long nights) { + this.nights = nights; + return this; + } - private Long checkoutAt; + /** Number of rooms, cabanas, apartments, and so on. */ + public Builder setNumberOfRooms(Long numberOfRooms) { + this.numberOfRooms = numberOfRooms; + return this; + } - private String customerServicePhoneNumber; + /** Rate type. */ + public Builder setRateType(String rateType) { + this.rateType = rateType; + return this; + } - private Map extraParams; + /** Whether smoking is allowed. */ + public Builder setSmokingIndicator(Boolean smokingIndicator) { + this.smokingIndicator = smokingIndicator; + return this; + } + } - private Boolean fireSafetyActComplianceIndicator; + public enum AccommodationType implements ApiRequestParams.EnumParam { + @SerializedName("apartment") + APARTMENT("apartment"), - private List guests; + @SerializedName("cabana") + CABANA("cabana"), - private Host host; + @SerializedName("house") + HOUSE("house"), - private List insurances; + @SerializedName("penthouse") + PENTHOUSE("penthouse"), - private Boolean noShowIndicator; + @SerializedName("room") + ROOM("room"), - private String renterIdNumber; + @SerializedName("standard") + STANDARD("standard"), - private String renterName; + @SerializedName("suite") + SUITE("suite"), - private Total total; + @SerializedName("villa") + VILLA("villa"); - /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.LodgingData build() { - return new ChargeCaptureParams.PaymentDetails.LodgingData( - this.accommodation, - this.affiliate, - this.bookingNumber, - this.checkinAt, - this.checkoutAt, - this.customerServicePhoneNumber, - this.extraParams, - this.fireSafetyActComplianceIndicator, - this.guests, - this.host, - this.insurances, - this.noShowIndicator, - this.renterIdNumber, - this.renterName, - this.total); - } + @Getter(onMethod_ = {@Override}) + private final String value; - /** Accommodation details for the lodging. */ - public Builder setAccommodation( - ChargeCaptureParams.PaymentDetails.LodgingData.Accommodation accommodation) { - this.accommodation = accommodation; - return this; + AccommodationType(String value) { + this.value = value; + } } + } - /** Affiliate details if applicable. */ - public Builder setAffiliate( - ChargeCaptureParams.PaymentDetails.LodgingData.Affiliate affiliate) { - this.affiliate = affiliate; - return this; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Affiliate { + /** Affiliate partner code. */ + @SerializedName("code") + String code; - /** Booking confirmation number for the lodging. */ - public Builder setBookingNumber(String bookingNumber) { - this.bookingNumber = bookingNumber; - return this; - } + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Required. Check-in date. */ - public Builder setCheckinAt(Long checkinAt) { - this.checkinAt = checkinAt; - return this; - } + /** Affiliate partner name. */ + @SerializedName("name") + String name; - /** Required. Check-out date. */ - public Builder setCheckoutAt(Long checkoutAt) { - this.checkoutAt = checkoutAt; - return this; + private Affiliate(String code, Map extraParams, String name) { + this.code = code; + this.extraParams = extraParams; + this.name = name; } - /** Customer service phone number for the lodging company. */ - public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { - this.customerServicePhoneNumber = customerServicePhoneNumber; - return this; + public static Builder builder() { + return new Builder(); } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData#extraParams} for the field - * documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + public static class Builder { + private String code; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData#extraParams} for the field - * documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + private Map extraParams; - /** Whether the lodging is compliant with any hotel fire safety regulations. */ - public Builder setFireSafetyActComplianceIndicator( - Boolean fireSafetyActComplianceIndicator) { - this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; - return this; - } + private String name; - /** - * Add an element to `guests` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData#guests} for the field documentation. - */ - public Builder addGuest(ChargeCaptureParams.PaymentDetails.LodgingData.Guest element) { - if (this.guests == null) { - this.guests = new ArrayList<>(); + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.LodgingData.Affiliate build() { + return new ChargeCaptureParams.PaymentDetails.LodgingData.Affiliate( + this.code, this.extraParams, this.name); } - this.guests.add(element); - return this; - } - /** - * Add all elements to `guests` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData#guests} for the field documentation. - */ - public Builder addAllGuest( - List elements) { - if (this.guests == null) { - this.guests = new ArrayList<>(); + /** Affiliate partner code. */ + public Builder setCode(String code) { + this.code = code; + return this; } - this.guests.addAll(elements); - return this; - } - /** Host details for the lodging. */ - public Builder setHost(ChargeCaptureParams.PaymentDetails.LodgingData.Host host) { - this.host = host; - return this; - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Affiliate#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** - * Add an element to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData#insurances} for the field documentation. - */ - public Builder addInsurance( - ChargeCaptureParams.PaymentDetails.LodgingData.Insurance element) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Affiliate#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; } - this.insurances.add(element); - return this; - } - /** - * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData#insurances} for the field documentation. - */ - public Builder addAllInsurance( - List elements) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); + /** Affiliate partner name. */ + public Builder setName(String name) { + this.name = name; + return this; } - this.insurances.addAll(elements); - return this; } + } - /** Whether the renter is a no-show. */ - public Builder setNoShowIndicator(Boolean noShowIndicator) { - this.noShowIndicator = noShowIndicator; - return this; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Guest { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Renter ID number for the lodging. */ - public Builder setRenterIdNumber(String renterIdNumber) { - this.renterIdNumber = renterIdNumber; - return this; + /** Required. Guest's full name. */ + @SerializedName("name") + String name; + + private Guest(Map extraParams, String name) { + this.extraParams = extraParams; + this.name = name; } - /** Renter name for the lodging. */ - public Builder setRenterName(String renterName) { - this.renterName = renterName; - return this; + public static Builder builder() { + return new Builder(); } - /** Required. Total details for the lodging. */ - public Builder setTotal(ChargeCaptureParams.PaymentDetails.LodgingData.Total total) { - this.total = total; - return this; + public static class Builder { + private Map extraParams; + + private String name; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.LodgingData.Guest build() { + return new ChargeCaptureParams.PaymentDetails.LodgingData.Guest( + this.extraParams, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Guest#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Guest#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Required. Guest's full name. */ + public Builder setName(String name) { + this.name = name; + return this; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Accommodation { - /** Type of accommodation. */ - @SerializedName("accommodation_type") - AccommodationType accommodationType; - - /** Bed type. */ - @SerializedName("bed_type") - String bedType; + public static class Host { + /** Address of the host. */ + @SerializedName("address") + Address address; - /** Daily accommodation rate in cents. */ - @SerializedName("daily_rate_amount") - Long dailyRateAmount; + /** Host's country of domicile. */ + @SerializedName("country_of_domicile") + String countryOfDomicile; /** * Map of extra parameters for custom features not available in this client library. The @@ -8964,39 +10377,49 @@ public static class Accommodation { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Number of nights. */ - @SerializedName("nights") - Long nights; + /** Reference number for the host. */ + @SerializedName("host_reference") + String hostReference; - /** Number of rooms, cabanas, apartments, and so on. */ - @SerializedName("number_of_rooms") - Long numberOfRooms; + /** Type of host. */ + @SerializedName("host_type") + HostType hostType; - /** Rate type. */ - @SerializedName("rate_type") - String rateType; + /** Name of the lodging property or host. */ + @SerializedName("name") + String name; - /** Whether smoking is allowed. */ - @SerializedName("smoking_indicator") - Boolean smokingIndicator; + /** Total number of reservations for the host. */ + @SerializedName("number_of_reservations") + Long numberOfReservations; - private Accommodation( - AccommodationType accommodationType, - String bedType, - Long dailyRateAmount, + /** Property phone number. */ + @SerializedName("property_phone_number") + String propertyPhoneNumber; + + /** Host's registration date. */ + @SerializedName("registered_at") + Long registeredAt; + + private Host( + Address address, + String countryOfDomicile, Map extraParams, - Long nights, - Long numberOfRooms, - String rateType, - Boolean smokingIndicator) { - this.accommodationType = accommodationType; - this.bedType = bedType; - this.dailyRateAmount = dailyRateAmount; + String hostReference, + HostType hostType, + String name, + Long numberOfReservations, + String propertyPhoneNumber, + Long registeredAt) { + this.address = address; + this.countryOfDomicile = countryOfDomicile; this.extraParams = extraParams; - this.nights = nights; - this.numberOfRooms = numberOfRooms; - this.rateType = rateType; - this.smokingIndicator = smokingIndicator; + this.hostReference = hostReference; + this.hostType = hostType; + this.name = name; + this.numberOfReservations = numberOfReservations; + this.propertyPhoneNumber = propertyPhoneNumber; + this.registeredAt = registeredAt; } public static Builder builder() { @@ -9004,61 +10427,56 @@ public static Builder builder() { } public static class Builder { - private AccommodationType accommodationType; - - private String bedType; + private Address address; - private Long dailyRateAmount; + private String countryOfDomicile; private Map extraParams; - private Long nights; + private String hostReference; - private Long numberOfRooms; + private HostType hostType; - private String rateType; + private String name; - private Boolean smokingIndicator; + private Long numberOfReservations; + + private String propertyPhoneNumber; + + private Long registeredAt; /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.LodgingData.Accommodation build() { - return new ChargeCaptureParams.PaymentDetails.LodgingData.Accommodation( - this.accommodationType, - this.bedType, - this.dailyRateAmount, + public ChargeCaptureParams.PaymentDetails.LodgingData.Host build() { + return new ChargeCaptureParams.PaymentDetails.LodgingData.Host( + this.address, + this.countryOfDomicile, this.extraParams, - this.nights, - this.numberOfRooms, - this.rateType, - this.smokingIndicator); - } - - /** Type of accommodation. */ - public Builder setAccommodationType( - ChargeCaptureParams.PaymentDetails.LodgingData.Accommodation.AccommodationType - accommodationType) { - this.accommodationType = accommodationType; - return this; + this.hostReference, + this.hostType, + this.name, + this.numberOfReservations, + this.propertyPhoneNumber, + this.registeredAt); } - /** Bed type. */ - public Builder setBedType(String bedType) { - this.bedType = bedType; + /** Address of the host. */ + public Builder setAddress( + ChargeCaptureParams.PaymentDetails.LodgingData.Host.Address address) { + this.address = address; return this; } - /** Daily accommodation rate in cents. */ - public Builder setDailyRateAmount(Long dailyRateAmount) { - this.dailyRateAmount = dailyRateAmount; + /** Host's country of domicile. */ + public Builder setCountryOfDomicile(String countryOfDomicile) { + this.countryOfDomicile = countryOfDomicile; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData.Accommodation#extraParams} for the field - * documentation. + * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Host#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -9071,9 +10489,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData.Accommodation#extraParams} for the field - * documentation. + * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Host#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -9083,154 +10500,247 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Number of nights. */ - public Builder setNights(Long nights) { - this.nights = nights; + /** Reference number for the host. */ + public Builder setHostReference(String hostReference) { + this.hostReference = hostReference; + return this; + } + + /** Type of host. */ + public Builder setHostType( + ChargeCaptureParams.PaymentDetails.LodgingData.Host.HostType hostType) { + this.hostType = hostType; + return this; + } + + /** Name of the lodging property or host. */ + public Builder setName(String name) { + this.name = name; return this; } - /** Number of rooms, cabanas, apartments, and so on. */ - public Builder setNumberOfRooms(Long numberOfRooms) { - this.numberOfRooms = numberOfRooms; + /** Total number of reservations for the host. */ + public Builder setNumberOfReservations(Long numberOfReservations) { + this.numberOfReservations = numberOfReservations; return this; } - /** Rate type. */ - public Builder setRateType(String rateType) { - this.rateType = rateType; + /** Property phone number. */ + public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { + this.propertyPhoneNumber = propertyPhoneNumber; return this; } - /** Whether smoking is allowed. */ - public Builder setSmokingIndicator(Boolean smokingIndicator) { - this.smokingIndicator = smokingIndicator; + /** Host's registration date. */ + public Builder setRegisteredAt(Long registeredAt) { + this.registeredAt = registeredAt; return this; } } - public enum AccommodationType implements ApiRequestParams.EnumParam { - @SerializedName("apartment") - APARTMENT("apartment"), - - @SerializedName("cabana") - CABANA("cabana"), + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Address { + /** Required. City, district, suburb, town, or village. */ + @SerializedName("city") + String city; - @SerializedName("house") - HOUSE("house"), + /** + * Required. Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + String country; - @SerializedName("penthouse") - PENTHOUSE("penthouse"), + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - @SerializedName("room") - ROOM("room"), + /** + * Required. Address line 1, such as the street, PO Box, or company name. + */ + @SerializedName("line1") + String line1; - @SerializedName("standard") - STANDARD("standard"), + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; - @SerializedName("suite") - SUITE("suite"), + /** Required. ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; - @SerializedName("villa") - VILLA("villa"); + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; - @Getter(onMethod_ = {@Override}) - private final String value; + private Address( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } - AccommodationType(String value) { - this.value = value; + public static Builder builder() { + return new Builder(); } - } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Affiliate { - /** Affiliate partner code. */ - @SerializedName("code") - String code; + public static class Builder { + private String city; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private String country; - /** Affiliate partner name. */ - @SerializedName("name") - String name; + private Map extraParams; - private Affiliate(String code, Map extraParams, String name) { - this.code = code; - this.extraParams = extraParams; - this.name = name; - } + private String line1; - public static Builder builder() { - return new Builder(); - } + private String line2; - public static class Builder { - private String code; + private String postalCode; - private Map extraParams; + private String state; - private String name; + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.LodgingData.Host.Address build() { + return new ChargeCaptureParams.PaymentDetails.LodgingData.Host.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } - /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.LodgingData.Affiliate build() { - return new ChargeCaptureParams.PaymentDetails.LodgingData.Affiliate( - this.code, this.extraParams, this.name); - } + /** Required. City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } - /** Affiliate partner code. */ - public Builder setCode(String code) { - this.code = code; - return this; - } + /** + * Required. Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Affiliate#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData.Host.Address#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; } - this.extraParams.put(key, value); - return this; - } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Affiliate#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData.Host.Address#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. Address line 1, such as the street, PO Box, or company + * name. + */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } + + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } + + /** Required. ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } + + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; } - this.extraParams.putAll(map); - return this; } + } + + public enum HostType implements ApiRequestParams.EnumParam { + @SerializedName("hostel") + HOSTEL("hostel"), + + @SerializedName("hotel") + HOTEL("hotel"), - /** Affiliate partner name. */ - public Builder setName(String name) { - this.name = name; - return this; + @SerializedName("owner") + OWNER("owner"), + + @SerializedName("rental_agency") + RENTAL_AGENCY("rental_agency"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + HostType(String value) { + this.value = value; } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Guest { + public static class Insurance { + /** Required. Price of the insurance coverage in cents. */ + @SerializedName("amount") + Long amount; + + /** Currency of the insurance amount. */ + @SerializedName("currency") + String currency; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -9241,13 +10751,25 @@ public static class Guest { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Required. Guest's full name. */ - @SerializedName("name") - String name; + /** Name of the insurance company. */ + @SerializedName("insurance_company_name") + String insuranceCompanyName; - private Guest(Map extraParams, String name) { + /** Required. Type of insurance coverage. */ + @SerializedName("insurance_type") + InsuranceType insuranceType; + + private Insurance( + Long amount, + String currency, + Map extraParams, + String insuranceCompanyName, + InsuranceType insuranceType) { + this.amount = amount; + this.currency = currency; this.extraParams = extraParams; - this.name = name; + this.insuranceCompanyName = insuranceCompanyName; + this.insuranceType = insuranceType; } public static Builder builder() { @@ -9255,21 +10777,43 @@ public static Builder builder() { } public static class Builder { + private Long amount; + + private String currency; + private Map extraParams; - private String name; + private String insuranceCompanyName; + + private InsuranceType insuranceType; /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.LodgingData.Guest build() { - return new ChargeCaptureParams.PaymentDetails.LodgingData.Guest( - this.extraParams, this.name); + public ChargeCaptureParams.PaymentDetails.LodgingData.Insurance build() { + return new ChargeCaptureParams.PaymentDetails.LodgingData.Insurance( + this.amount, + this.currency, + this.extraParams, + this.insuranceCompanyName, + this.insuranceType); + } + + /** Required. Price of the insurance coverage in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Currency of the insurance amount. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Guest#extraParams} for - * the field documentation. + * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Insurance#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -9282,8 +10826,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Guest#extraParams} for - * the field documentation. + * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Insurance#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -9293,24 +10837,65 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Required. Guest's full name. */ - public Builder setName(String name) { - this.name = name; + /** Name of the insurance company. */ + public Builder setInsuranceCompanyName(String insuranceCompanyName) { + this.insuranceCompanyName = insuranceCompanyName; + return this; + } + + /** Required. Type of insurance coverage. */ + public Builder setInsuranceType( + ChargeCaptureParams.PaymentDetails.LodgingData.Insurance.InsuranceType + insuranceType) { + this.insuranceType = insuranceType; return this; } } + + public enum InsuranceType implements ApiRequestParams.EnumParam { + @SerializedName("bankruptcy") + BANKRUPTCY("bankruptcy"), + + @SerializedName("cancelation") + CANCELATION("cancelation"), + + @SerializedName("emergency") + EMERGENCY("emergency"), + + @SerializedName("medical") + MEDICAL("medical"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + InsuranceType(String value) { + this.value = value; + } + } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Host { - /** Address of the host. */ - @SerializedName("address") - Address address; + public static class Total { + /** Required. Total price of the lodging reservation in cents. */ + @SerializedName("amount") + Long amount; - /** Host's country of domicile. */ - @SerializedName("country_of_domicile") - String countryOfDomicile; + /** Cash advances in cents. */ + @SerializedName("cash_advances") + Long cashAdvances; + + /** Currency of the total amount. */ + @SerializedName("currency") + String currency; + + /** Discount details for the lodging. */ + @SerializedName("discounts") + Discounts discounts; + + /** Additional charges for the lodging. */ + @SerializedName("extra_charges") + List extraCharges; /** * Map of extra parameters for custom features not available in this client library. The @@ -9322,49 +10907,31 @@ public static class Host { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Reference number for the host. */ - @SerializedName("host_reference") - String hostReference; - - /** Type of host. */ - @SerializedName("host_type") - HostType hostType; - - /** Name of the lodging property or host. */ - @SerializedName("name") - String name; - - /** Total number of reservations for the host. */ - @SerializedName("number_of_reservations") - Long numberOfReservations; - - /** Property phone number. */ - @SerializedName("property_phone_number") - String propertyPhoneNumber; + /** Prepaid amount in cents. */ + @SerializedName("prepaid_amount") + Long prepaidAmount; - /** Host's registration date. */ - @SerializedName("registered_at") - Long registeredAt; + /** Tax breakdown for the lodging reservation. */ + @SerializedName("tax") + Tax tax; - private Host( - Address address, - String countryOfDomicile, + private Total( + Long amount, + Long cashAdvances, + String currency, + Discounts discounts, + List extraCharges, Map extraParams, - String hostReference, - HostType hostType, - String name, - Long numberOfReservations, - String propertyPhoneNumber, - Long registeredAt) { - this.address = address; - this.countryOfDomicile = countryOfDomicile; + Long prepaidAmount, + Tax tax) { + this.amount = amount; + this.cashAdvances = cashAdvances; + this.currency = currency; + this.discounts = discounts; + this.extraCharges = extraCharges; this.extraParams = extraParams; - this.hostReference = hostReference; - this.hostType = hostType; - this.name = name; - this.numberOfReservations = numberOfReservations; - this.propertyPhoneNumber = propertyPhoneNumber; - this.registeredAt = registeredAt; + this.prepaidAmount = prepaidAmount; + this.tax = tax; } public static Builder builder() { @@ -9372,55 +10939,95 @@ public static Builder builder() { } public static class Builder { - private Address address; - - private String countryOfDomicile; + private Long amount; - private Map extraParams; + private Long cashAdvances; - private String hostReference; + private String currency; - private HostType hostType; + private Discounts discounts; - private String name; + private List + extraCharges; - private Long numberOfReservations; + private Map extraParams; - private String propertyPhoneNumber; + private Long prepaidAmount; - private Long registeredAt; + private Tax tax; /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.LodgingData.Host build() { - return new ChargeCaptureParams.PaymentDetails.LodgingData.Host( - this.address, - this.countryOfDomicile, + public ChargeCaptureParams.PaymentDetails.LodgingData.Total build() { + return new ChargeCaptureParams.PaymentDetails.LodgingData.Total( + this.amount, + this.cashAdvances, + this.currency, + this.discounts, + this.extraCharges, this.extraParams, - this.hostReference, - this.hostType, - this.name, - this.numberOfReservations, - this.propertyPhoneNumber, - this.registeredAt); + this.prepaidAmount, + this.tax); + } + + /** Required. Total price of the lodging reservation in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Cash advances in cents. */ + public Builder setCashAdvances(Long cashAdvances) { + this.cashAdvances = cashAdvances; + return this; } - /** Address of the host. */ - public Builder setAddress( - ChargeCaptureParams.PaymentDetails.LodgingData.Host.Address address) { - this.address = address; + /** Currency of the total amount. */ + public Builder setCurrency(String currency) { + this.currency = currency; return this; } - /** Host's country of domicile. */ - public Builder setCountryOfDomicile(String countryOfDomicile) { - this.countryOfDomicile = countryOfDomicile; + /** Discount details for the lodging. */ + public Builder setDiscounts( + ChargeCaptureParams.PaymentDetails.LodgingData.Total.Discounts discounts) { + this.discounts = discounts; + return this; + } + + /** + * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData.Total#extraCharges} for the field + * documentation. + */ + public Builder addExtraCharge( + ChargeCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge element) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.add(element); + return this; + } + + /** + * Add all elements to `extraCharges` list. A list is initialized for the first + * `add/addAll` call, and subsequent calls adds additional elements to the original list. + * See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Total#extraCharges} for the + * field documentation. + */ + public Builder addAllExtraCharge( + List elements) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.addAll(elements); return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Host#extraParams} for + * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Total#extraParams} for * the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -9434,7 +11041,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Host#extraParams} for + * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Total#extraParams} for * the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -9445,58 +11052,227 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Reference number for the host. */ - public Builder setHostReference(String hostReference) { - this.hostReference = hostReference; + /** Prepaid amount in cents. */ + public Builder setPrepaidAmount(Long prepaidAmount) { + this.prepaidAmount = prepaidAmount; return this; } - /** Type of host. */ - public Builder setHostType( - ChargeCaptureParams.PaymentDetails.LodgingData.Host.HostType hostType) { - this.hostType = hostType; + /** Tax breakdown for the lodging reservation. */ + public Builder setTax(ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax tax) { + this.tax = tax; return this; } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Discounts { + /** Corporate client discount code. */ + @SerializedName("corporate_client_code") + String corporateClientCode; + + /** Coupon code. */ + @SerializedName("coupon") + String coupon; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Discounts( + String corporateClientCode, String coupon, Map extraParams) { + this.corporateClientCode = corporateClientCode; + this.coupon = coupon; + this.extraParams = extraParams; + } - /** Name of the lodging property or host. */ - public Builder setName(String name) { - this.name = name; - return this; + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String corporateClientCode; + + private String coupon; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.LodgingData.Total.Discounts build() { + return new ChargeCaptureParams.PaymentDetails.LodgingData.Total.Discounts( + this.corporateClientCode, this.coupon, this.extraParams); + } + + /** Corporate client discount code. */ + public Builder setCorporateClientCode(String corporateClientCode) { + this.corporateClientCode = corporateClientCode; + return this; + } + + /** Coupon code. */ + public Builder setCoupon(String coupon) { + this.coupon = coupon; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ExtraCharge { + /** Amount of the extra charge in cents. */ + @SerializedName("amount") + Long amount; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Type of extra charge. */ + @SerializedName("type") + Type type; + + private ExtraCharge(Long amount, Map extraParams, Type type) { + this.amount = amount; + this.extraParams = extraParams; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private Map extraParams; + + private Type type; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge build() { + return new ChargeCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge( + this.amount, this.extraParams, this.type); + } + + /** Amount of the extra charge in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Type of extra charge. */ + public Builder setType( + ChargeCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge.Type type) { + this.type = type; + return this; + } } - /** Total number of reservations for the host. */ - public Builder setNumberOfReservations(Long numberOfReservations) { - this.numberOfReservations = numberOfReservations; - return this; - } + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("gift_shop") + GIFT_SHOP("gift_shop"), + + @SerializedName("laundry") + LAUNDRY("laundry"), + + @SerializedName("mini_bar") + MINI_BAR("mini_bar"), + + @SerializedName("other") + OTHER("other"), + + @SerializedName("phone") + PHONE("phone"), - /** Property phone number. */ - public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { - this.propertyPhoneNumber = propertyPhoneNumber; - return this; - } + @SerializedName("restaurant") + RESTAURANT("restaurant"); - /** Host's registration date. */ - public Builder setRegisteredAt(Long registeredAt) { - this.registeredAt = registeredAt; - return this; + @Getter(onMethod_ = {@Override}) + private final String value; + + Type(String value) { + this.value = value; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Address { - /** Required. City, district, suburb, town, or village. */ - @SerializedName("city") - String city; - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - @SerializedName("country") - String country; - + public static class Tax { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -9507,42 +11283,21 @@ public static class Address { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** - * Required. Address line 1, such as the street, PO Box, or company name. - */ - @SerializedName("line1") - String line1; - - /** Address line 2, such as the apartment, suite, unit, or building. */ - @SerializedName("line2") - String line2; - - /** Required. ZIP or postal code. */ - @SerializedName("postal_code") - String postalCode; + /** Indicates whether the transaction is tax exempt. */ + @SerializedName("tax_exempt_indicator") + Boolean taxExemptIndicator; - /** - * State, county, province, or region (ISO 3166-2). - */ - @SerializedName("state") - String state; + /** Tax details. */ + @SerializedName("taxes") + List taxes; - private Address( - String city, - String country, + private Tax( Map extraParams, - String line1, - String line2, - String postalCode, - String state) { - this.city = city; - this.country = country; + Boolean taxExemptIndicator, + List taxes) { this.extraParams = extraParams; - this.line1 = line1; - this.line2 = line2; - this.postalCode = postalCode; - this.state = state; + this.taxExemptIndicator = taxExemptIndicator; + this.taxes = taxes; } public static Builder builder() { @@ -9550,53 +11305,24 @@ public static Builder builder() { } public static class Builder { - private String city; - - private String country; - private Map extraParams; - private String line1; - - private String line2; - - private String postalCode; + private Boolean taxExemptIndicator; - private String state; + private List taxes; /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.LodgingData.Host.Address build() { - return new ChargeCaptureParams.PaymentDetails.LodgingData.Host.Address( - this.city, - this.country, - this.extraParams, - this.line1, - this.line2, - this.postalCode, - this.state); - } - - /** Required. City, district, suburb, town, or village. */ - public Builder setCity(String city) { - this.city = city; - return this; - } - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - public Builder setCountry(String country) { - this.country = country; - return this; + public ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax build() { + return new ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax( + this.extraParams, this.taxExemptIndicator, this.taxes); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData.Host.Address#extraParams} for the - * field documentation. + * ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the field + * documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -9610,8 +11336,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData.Host.Address#extraParams} for the - * field documentation. + * ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the field + * documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -9621,226 +11347,258 @@ public Builder putAllExtraParam(Map map) { return this; } + /** Indicates whether the transaction is tax exempt. */ + public Builder setTaxExemptIndicator(Boolean taxExemptIndicator) { + this.taxExemptIndicator = taxExemptIndicator; + return this; + } + /** - * Required. Address line 1, such as the street, PO Box, or company - * name. + * Add an element to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field + * documentation. */ - public Builder setLine1(String line1) { - this.line1 = line1; + public Builder addTax( + ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax element) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.add(element); return this; } - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(String line2) { - this.line2 = line2; + /** + * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field + * documentation. + */ + public Builder addAllTax( + List elements) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.addAll(elements); return this; } + } - /** Required. ZIP or postal code. */ - public Builder setPostalCode(String postalCode) { - this.postalCode = postalCode; - return this; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class InnerTax { + /** Tax amount in cents. */ + @SerializedName("amount") + Long amount; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Tax rate. */ + @SerializedName("rate") + Long rate; + + /** Type of tax applied. */ + @SerializedName("type") + String type; + + private InnerTax(Long amount, Map extraParams, Long rate, String type) { + this.amount = amount; + this.extraParams = extraParams; + this.rate = rate; + this.type = type; + } + + public static Builder builder() { + return new Builder(); } - /** - * State, county, province, or region (ISO 3166-2). - */ - public Builder setState(String state) { - this.state = state; - return this; + public static class Builder { + private Long amount; + + private Map extraParams; + + private Long rate; + + private String type; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax build() { + return new ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax( + this.amount, this.extraParams, this.rate, this.type); + } + + /** Tax amount in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Tax rate. */ + public Builder setRate(Long rate) { + this.rate = rate; + return this; + } + + /** Type of tax applied. */ + public Builder setType(String type) { + this.type = type; + return this; + } } } } + } + } - public enum HostType implements ApiRequestParams.EnumParam { - @SerializedName("hostel") - HOSTEL("hostel"), - - @SerializedName("hotel") - HOTEL("hotel"), - - @SerializedName("owner") - OWNER("owner"), + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Account funding transaction details including sender and beneficiary information. */ + @SerializedName("account_funding") + Object accountFunding; - @SerializedName("rental_agency") - RENTAL_AGENCY("rental_agency"); + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - @Getter(onMethod_ = {@Override}) - private final String value; + /** The type of money services transaction. */ + @SerializedName("transaction_type") + ApiRequestParams.EnumParam transactionType; - HostType(String value) { - this.value = value; - } - } + private MoneyServices( + Object accountFunding, + Map extraParams, + ApiRequestParams.EnumParam transactionType) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + this.transactionType = transactionType; } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Insurance { - /** Required. Price of the insurance coverage in cents. */ - @SerializedName("amount") - Long amount; - - /** Currency of the insurance amount. */ - @SerializedName("currency") - String currency; + public static Builder builder() { + return new Builder(); + } - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public static class Builder { + private Object accountFunding; - /** Name of the insurance company. */ - @SerializedName("insurance_company_name") - String insuranceCompanyName; + private Map extraParams; - /** Required. Type of insurance coverage. */ - @SerializedName("insurance_type") - InsuranceType insuranceType; + private ApiRequestParams.EnumParam transactionType; - private Insurance( - Long amount, - String currency, - Map extraParams, - String insuranceCompanyName, - InsuranceType insuranceType) { - this.amount = amount; - this.currency = currency; - this.extraParams = extraParams; - this.insuranceCompanyName = insuranceCompanyName; - this.insuranceType = insuranceType; + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.MoneyServices build() { + return new ChargeCaptureParams.PaymentDetails.MoneyServices( + this.accountFunding, this.extraParams, this.transactionType); } - public static Builder builder() { - return new Builder(); + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding( + ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { + this.accountFunding = accountFunding; + return this; } - public static class Builder { - private Long amount; - - private String currency; - - private Map extraParams; - - private String insuranceCompanyName; - - private InsuranceType insuranceType; - - /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.LodgingData.Insurance build() { - return new ChargeCaptureParams.PaymentDetails.LodgingData.Insurance( - this.amount, - this.currency, - this.extraParams, - this.insuranceCompanyName, - this.insuranceType); - } - - /** Required. Price of the insurance coverage in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } - - /** Currency of the insurance amount. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; - } - - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Insurance#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } - - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Insurance#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding(EmptyParam accountFunding) { + this.accountFunding = accountFunding; + return this; + } - /** Name of the insurance company. */ - public Builder setInsuranceCompanyName(String insuranceCompanyName) { - this.insuranceCompanyName = insuranceCompanyName; - return this; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.MoneyServices#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.put(key, value); + return this; + } - /** Required. Type of insurance coverage. */ - public Builder setInsuranceType( - ChargeCaptureParams.PaymentDetails.LodgingData.Insurance.InsuranceType - insuranceType) { - this.insuranceType = insuranceType; - return this; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeCaptureParams.PaymentDetails.MoneyServices#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.putAll(map); + return this; } - public enum InsuranceType implements ApiRequestParams.EnumParam { - @SerializedName("bankruptcy") - BANKRUPTCY("bankruptcy"), - - @SerializedName("cancelation") - CANCELATION("cancelation"), - - @SerializedName("emergency") - EMERGENCY("emergency"), - - @SerializedName("medical") - MEDICAL("medical"); - - @Getter(onMethod_ = {@Override}) - private final String value; + /** The type of money services transaction. */ + public Builder setTransactionType( + ChargeCaptureParams.PaymentDetails.MoneyServices.TransactionType transactionType) { + this.transactionType = transactionType; + return this; + } - InsuranceType(String value) { - this.value = value; - } + /** The type of money services transaction. */ + public Builder setTransactionType(EmptyParam transactionType) { + this.transactionType = transactionType; + return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Total { - /** Required. Total price of the lodging reservation in cents. */ - @SerializedName("amount") - Long amount; - - /** Cash advances in cents. */ - @SerializedName("cash_advances") - Long cashAdvances; - - /** Currency of the total amount. */ - @SerializedName("currency") - String currency; - - /** Discount details for the lodging. */ - @SerializedName("discounts") - Discounts discounts; + public static class AccountFunding { + /** ID of the Account representing the beneficiary in this account funding transaction. */ + @SerializedName("beneficiary_account") + String beneficiaryAccount; - /** Additional charges for the lodging. */ - @SerializedName("extra_charges") - List extraCharges; + /** Inline identity details for the beneficiary of this account funding transaction. */ + @SerializedName("beneficiary_details") + Object beneficiaryDetails; /** * Map of extra parameters for custom features not available in this client library. The @@ -9852,31 +11610,25 @@ public static class Total { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Prepaid amount in cents. */ - @SerializedName("prepaid_amount") - Long prepaidAmount; - - /** Tax breakdown for the lodging reservation. */ - @SerializedName("tax") - Tax tax; + /** ID of the Account representing the sender in this account funding transaction. */ + @SerializedName("sender_account") + String senderAccount; - private Total( - Long amount, - Long cashAdvances, - String currency, - Discounts discounts, - List extraCharges, + /** Inline identity details for the sender of this account funding transaction. */ + @SerializedName("sender_details") + Object senderDetails; + + private AccountFunding( + String beneficiaryAccount, + Object beneficiaryDetails, Map extraParams, - Long prepaidAmount, - Tax tax) { - this.amount = amount; - this.cashAdvances = cashAdvances; - this.currency = currency; - this.discounts = discounts; - this.extraCharges = extraCharges; + String senderAccount, + Object senderDetails) { + this.beneficiaryAccount = beneficiaryAccount; + this.beneficiaryDetails = beneficiaryDetails; this.extraParams = extraParams; - this.prepaidAmount = prepaidAmount; - this.tax = tax; + this.senderAccount = senderAccount; + this.senderDetails = senderDetails; } public static Builder builder() { @@ -9884,96 +11636,52 @@ public static Builder builder() { } public static class Builder { - private Long amount; - - private Long cashAdvances; - - private String currency; + private String beneficiaryAccount; - private Discounts discounts; - - private List - extraCharges; + private Object beneficiaryDetails; private Map extraParams; - private Long prepaidAmount; + private String senderAccount; - private Tax tax; + private Object senderDetails; /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.LodgingData.Total build() { - return new ChargeCaptureParams.PaymentDetails.LodgingData.Total( - this.amount, - this.cashAdvances, - this.currency, - this.discounts, - this.extraCharges, + public ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding build() { + return new ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding( + this.beneficiaryAccount, + this.beneficiaryDetails, this.extraParams, - this.prepaidAmount, - this.tax); - } - - /** Required. Total price of the lodging reservation in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } - - /** Cash advances in cents. */ - public Builder setCashAdvances(Long cashAdvances) { - this.cashAdvances = cashAdvances; - return this; - } - - /** Currency of the total amount. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; + this.senderAccount, + this.senderDetails); } - /** Discount details for the lodging. */ - public Builder setDiscounts( - ChargeCaptureParams.PaymentDetails.LodgingData.Total.Discounts discounts) { - this.discounts = discounts; + /** ID of the Account representing the beneficiary in this account funding transaction. */ + public Builder setBeneficiaryAccount(String beneficiaryAccount) { + this.beneficiaryAccount = beneficiaryAccount; return this; } - /** - * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData.Total#extraCharges} for the field - * documentation. - */ - public Builder addExtraCharge( - ChargeCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge element) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.add(element); + /** Inline identity details for the beneficiary of this account funding transaction. */ + public Builder setBeneficiaryDetails( + ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails + beneficiaryDetails) { + this.beneficiaryDetails = beneficiaryDetails; return this; } - /** - * Add all elements to `extraCharges` list. A list is initialized for the first - * `add/addAll` call, and subsequent calls adds additional elements to the original list. - * See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Total#extraCharges} for the - * field documentation. - */ - public Builder addAllExtraCharge( - List elements) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.addAll(elements); + /** Inline identity details for the beneficiary of this account funding transaction. */ + public Builder setBeneficiaryDetails(EmptyParam beneficiaryDetails) { + this.beneficiaryDetails = beneficiaryDetails; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Total#extraParams} for - * the field documentation. + * map. See {@link + * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -9986,8 +11694,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.LodgingData.Total#extraParams} for - * the field documentation. + * map. See {@link + * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for the + * field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -9997,29 +11706,41 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Prepaid amount in cents. */ - public Builder setPrepaidAmount(Long prepaidAmount) { - this.prepaidAmount = prepaidAmount; + /** ID of the Account representing the sender in this account funding transaction. */ + public Builder setSenderAccount(String senderAccount) { + this.senderAccount = senderAccount; return this; } - /** Tax breakdown for the lodging reservation. */ - public Builder setTax(ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax tax) { - this.tax = tax; + /** Inline identity details for the sender of this account funding transaction. */ + public Builder setSenderDetails( + ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + senderDetails) { + this.senderDetails = senderDetails; + return this; + } + + /** Inline identity details for the sender of this account funding transaction. */ + public Builder setSenderDetails(EmptyParam senderDetails) { + this.senderDetails = senderDetails; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Discounts { - /** Corporate client discount code. */ - @SerializedName("corporate_client_code") - String corporateClientCode; + public static class BeneficiaryDetails { + /** Address. */ + @SerializedName("address") + Address address; - /** Coupon code. */ - @SerializedName("coupon") - String coupon; + /** Date of birth. */ + @SerializedName("date_of_birth") + DateOfBirth dateOfBirth; + + /** Email address. */ + @SerializedName("email") + String email; /** * Map of extra parameters for custom features not available in this client library. The @@ -10031,11 +11752,27 @@ public static class Discounts { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private Discounts( - String corporateClientCode, String coupon, Map extraParams) { - this.corporateClientCode = corporateClientCode; - this.coupon = coupon; + /** Full name. */ + @SerializedName("name") + String name; + + /** Phone number. */ + @SerializedName("phone") + String phone; + + private BeneficiaryDetails( + Address address, + DateOfBirth dateOfBirth, + String email, + Map extraParams, + String name, + String phone) { + this.address = address; + this.dateOfBirth = dateOfBirth; + this.email = email; this.extraParams = extraParams; + this.name = name; + this.phone = phone; } public static Builder builder() { @@ -10043,27 +11780,53 @@ public static Builder builder() { } public static class Builder { - private String corporateClientCode; + private Address address; - private String coupon; + private DateOfBirth dateOfBirth; + + private String email; private Map extraParams; + private String name; + + private String phone; + /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.LodgingData.Total.Discounts build() { - return new ChargeCaptureParams.PaymentDetails.LodgingData.Total.Discounts( - this.corporateClientCode, this.coupon, this.extraParams); + public ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails + build() { + return new ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails( + this.address, + this.dateOfBirth, + this.email, + this.extraParams, + this.name, + this.phone); } - /** Corporate client discount code. */ - public Builder setCorporateClientCode(String corporateClientCode) { - this.corporateClientCode = corporateClientCode; + /** Address. */ + public Builder setAddress( + ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails + .Address + address) { + this.address = address; return this; } - /** Coupon code. */ - public Builder setCoupon(String coupon) { - this.coupon = coupon; + /** Date of birth. */ + public Builder setDateOfBirth( + ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails + .DateOfBirth + dateOfBirth) { + this.dateOfBirth = dateOfBirth; + return this; + } + + /** Email address. */ + public Builder setEmail(String email) { + this.email = email; return this; } @@ -10071,8 +11834,8 @@ public Builder setCoupon(String coupon) { * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} for the - * field documentation. + * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -10086,138 +11849,318 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} for the - * field documentation. + * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { this.extraParams = new HashMap<>(); } - this.extraParams.putAll(map); - return this; - } - } - } + this.extraParams.putAll(map); + return this; + } + + /** Full name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** Phone number. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Address { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + String city; + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + String country; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Address line 1, such as the street, PO Box, or company name. */ + @SerializedName("line1") + String line1; + + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; + + /** ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; + + private Address( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String city; + + private String country; + + private Map extraParams; + + private String line1; + + private String line2; + + private String postalCode; + + private String state; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.Address + build() { + return new ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } + + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.Address#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.Address#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class ExtraCharge { - /** Amount of the extra charge in cents. */ - @SerializedName("amount") - Long amount; - - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } - /** Type of extra charge. */ - @SerializedName("type") - Type type; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } - private ExtraCharge(Long amount, Map extraParams, Type type) { - this.amount = amount; - this.extraParams = extraParams; - this.type = type; - } + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - public static Builder builder() { - return new Builder(); + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + } } - public static class Builder { - private Long amount; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class DateOfBirth { + /** Required. Day of birth, between 1 and 31. */ + @SerializedName("day") + Long day; - private Map extraParams; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private Type type; + /** Required. Month of birth, between 1 and 12. */ + @SerializedName("month") + Long month; - /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge build() { - return new ChargeCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge( - this.amount, this.extraParams, this.type); - } + /** Required. Four-digit year of birth. */ + @SerializedName("year") + Long year; - /** Amount of the extra charge in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; + private DateOfBirth(Long day, Map extraParams, Long month, Long year) { + this.day = day; + this.extraParams = extraParams; + this.month = month; + this.year = year; } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; + public static Builder builder() { + return new Builder(); } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + public static class Builder { + private Long day; - /** Type of extra charge. */ - public Builder setType( - ChargeCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge.Type type) { - this.type = type; - return this; - } - } + private Map extraParams; - public enum Type implements ApiRequestParams.EnumParam { - @SerializedName("gift_shop") - GIFT_SHOP("gift_shop"), + private Long month; - @SerializedName("laundry") - LAUNDRY("laundry"), + private Long year; - @SerializedName("mini_bar") - MINI_BAR("mini_bar"), + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.DateOfBirth + build() { + return new ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.DateOfBirth( + this.day, this.extraParams, this.month, this.year); + } - @SerializedName("other") - OTHER("other"), + /** Required. Day of birth, between 1 and 31. */ + public Builder setDay(Long day) { + this.day = day; + return this; + } - @SerializedName("phone") - PHONE("phone"), + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - @SerializedName("restaurant") - RESTAURANT("restaurant"); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** Required. Month of birth, between 1 and 12. */ + public Builder setMonth(Long month) { + this.month = month; + return this; + } - Type(String value) { - this.value = value; + /** Required. Four-digit year of birth. */ + public Builder setYear(Long year) { + this.year = year; + return this; + } } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Tax { + public static class SenderDetails { + /** Address. */ + @SerializedName("address") + Address address; + + /** Date of birth. */ + @SerializedName("date_of_birth") + DateOfBirth dateOfBirth; + + /** Email address. */ + @SerializedName("email") + String email; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -10228,21 +12171,27 @@ public static class Tax { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Indicates whether the transaction is tax exempt. */ - @SerializedName("tax_exempt_indicator") - Boolean taxExemptIndicator; + /** Full name. */ + @SerializedName("name") + String name; - /** Tax details. */ - @SerializedName("taxes") - List taxes; + /** Phone number. */ + @SerializedName("phone") + String phone; - private Tax( + private SenderDetails( + Address address, + DateOfBirth dateOfBirth, + String email, Map extraParams, - Boolean taxExemptIndicator, - List taxes) { + String name, + String phone) { + this.address = address; + this.dateOfBirth = dateOfBirth; + this.email = email; this.extraParams = extraParams; - this.taxExemptIndicator = taxExemptIndicator; - this.taxes = taxes; + this.name = name; + this.phone = phone; } public static Builder builder() { @@ -10250,24 +12199,61 @@ public static Builder builder() { } public static class Builder { + private Address address; + + private DateOfBirth dateOfBirth; + + private String email; + private Map extraParams; - private Boolean taxExemptIndicator; + private String name; - private List taxes; + private String phone; /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax build() { - return new ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax( - this.extraParams, this.taxExemptIndicator, this.taxes); + public ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + build() { + return new ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails( + this.address, + this.dateOfBirth, + this.email, + this.extraParams, + this.name, + this.phone); + } + + /** Address. */ + public Builder setAddress( + ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + .Address + address) { + this.address = address; + return this; + } + + /** Date of birth. */ + public Builder setDateOfBirth( + ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + .DateOfBirth + dateOfBirth) { + this.dateOfBirth = dateOfBirth; + return this; + } + + /** Email address. */ + public Builder setEmail(String email) { + this.email = email; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the field - * documentation. + * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -10281,8 +12267,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the field - * documentation. + * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -10292,50 +12278,33 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Indicates whether the transaction is tax exempt. */ - public Builder setTaxExemptIndicator(Boolean taxExemptIndicator) { - this.taxExemptIndicator = taxExemptIndicator; - return this; - } - - /** - * Add an element to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addTax( - ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax element) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.add(element); + /** Full name. */ + public Builder setName(String name) { + this.name = name; return this; } - /** - * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addAllTax( - List elements) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.addAll(elements); + /** Phone number. */ + public Builder setPhone(String phone) { + this.phone = phone; return this; } } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class InnerTax { - /** Tax amount in cents. */ - @SerializedName("amount") - Long amount; - + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Address { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + String city; + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + String country; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} @@ -10346,19 +12315,40 @@ public static class InnerTax { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Tax rate. */ - @SerializedName("rate") - Long rate; + /** Address line 1, such as the street, PO Box, or company name. */ + @SerializedName("line1") + String line1; - /** Type of tax applied. */ - @SerializedName("type") - String type; + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; - private InnerTax(Long amount, Map extraParams, Long rate, String type) { - this.amount = amount; + /** ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; + + private Address( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; this.extraParams = extraParams; - this.rate = rate; - this.type = type; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; } public static Builder builder() { @@ -10366,23 +12356,47 @@ public static Builder builder() { } public static class Builder { - private Long amount; + private String city; + + private String country; private Map extraParams; - private Long rate; + private String line1; - private String type; + private String line2; + + private String postalCode; + + private String state; /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax build() { - return new ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax( - this.amount, this.extraParams, this.rate, this.type); + public ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + .Address + build() { + return new ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); } - /** Tax amount in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; return this; } @@ -10390,8 +12404,8 @@ public Builder setAmount(Long amount) { * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} for - * the field documentation. + * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.Address#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -10405,8 +12419,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the * first `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} for - * the field documentation. + * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.Address#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -10416,174 +12430,136 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Tax rate. */ - public Builder setRate(Long rate) { - this.rate = rate; + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(String line1) { + this.line1 = line1; return this; } - /** Type of tax applied. */ - public Builder setType(String type) { - this.type = type; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; return this; } - } - } - } - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class MoneyServices { - /** Account funding transaction details including sender and beneficiary information. */ - @SerializedName("account_funding") - Object accountFunding; - - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) - * name in this param object. Effectively, this map is flattened to its parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; - - /** The type of money services transaction. */ - @SerializedName("transaction_type") - TransactionType transactionType; - private MoneyServices( - Object accountFunding, Map extraParams, TransactionType transactionType) { - this.accountFunding = accountFunding; - this.extraParams = extraParams; - this.transactionType = transactionType; - } + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - public static Builder builder() { - return new Builder(); - } + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + } + } - public static class Builder { - private Object accountFunding; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class DateOfBirth { + /** Required. Day of birth, between 1 and 31. */ + @SerializedName("day") + Long day; - private Map extraParams; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private TransactionType transactionType; + /** Required. Month of birth, between 1 and 12. */ + @SerializedName("month") + Long month; - /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.MoneyServices build() { - return new ChargeCaptureParams.PaymentDetails.MoneyServices( - this.accountFunding, this.extraParams, this.transactionType); - } + /** Required. Four-digit year of birth. */ + @SerializedName("year") + Long year; - /** Account funding transaction details including sender and beneficiary information. */ - public Builder setAccountFunding( - ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { - this.accountFunding = accountFunding; - return this; - } + private DateOfBirth(Long day, Map extraParams, Long month, Long year) { + this.day = day; + this.extraParams = extraParams; + this.month = month; + this.year = year; + } - /** Account funding transaction details including sender and beneficiary information. */ - public Builder setAccountFunding(EmptyParam accountFunding) { - this.accountFunding = accountFunding; - return this; - } + public static Builder builder() { + return new Builder(); + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.MoneyServices#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + public static class Builder { + private Long day; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeCaptureParams.PaymentDetails.MoneyServices#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + private Map extraParams; - /** The type of money services transaction. */ - public Builder setTransactionType( - ChargeCaptureParams.PaymentDetails.MoneyServices.TransactionType transactionType) { - this.transactionType = transactionType; - return this; - } - } + private Long month; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class AccountFunding { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private Long year; - private AccountFunding(Map extraParams) { - this.extraParams = extraParams; - } + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + .DateOfBirth + build() { + return new ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.DateOfBirth(this.day, this.extraParams, this.month, this.year); + } - public static Builder builder() { - return new Builder(); - } + /** Required. Day of birth, between 1 and 31. */ + public Builder setDay(Long day) { + this.day = day; + return this; + } - public static class Builder { - private Map extraParams; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** Finalize and obtain parameter instance from this builder. */ - public ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding build() { - return new ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding( - this.extraParams); - } + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Required. Month of birth, between 1 and 12. */ + public Builder setMonth(Long month) { + this.month = month; + return this; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** Required. Four-digit year of birth. */ + public Builder setYear(Long year) { + this.year = year; + return this; + } } - this.extraParams.putAll(map); - return this; } } } diff --git a/src/main/java/com/stripe/param/ChargeUpdateParams.java b/src/main/java/com/stripe/param/ChargeUpdateParams.java index 311c33a51d2..4f7f9ee9a6b 100644 --- a/src/main/java/com/stripe/param/ChargeUpdateParams.java +++ b/src/main/java/com/stripe/param/ChargeUpdateParams.java @@ -479,6 +479,10 @@ public static class PaymentDetails { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; + /** Fleet data for this PaymentIntent. */ + @SerializedName("fleet_data") + Object fleetData; + /** Flight reservation details for this PaymentIntent. */ @SerializedName("flight") Flight flight; @@ -520,6 +524,7 @@ private PaymentDetails( Object customerReference, EventDetails eventDetails, Map extraParams, + Object fleetData, Flight flight, Object flightData, Lodging lodging, @@ -532,6 +537,7 @@ private PaymentDetails( this.customerReference = customerReference; this.eventDetails = eventDetails; this.extraParams = extraParams; + this.fleetData = fleetData; this.flight = flight; this.flightData = flightData; this.lodging = lodging; @@ -556,6 +562,8 @@ public static class Builder { private Map extraParams; + private Object fleetData; + private Flight flight; private Object flightData; @@ -578,6 +586,7 @@ public ChargeUpdateParams.PaymentDetails build() { this.customerReference, this.eventDetails, this.extraParams, + this.fleetData, this.flight, this.flightData, this.lodging, @@ -690,6 +699,46 @@ public Builder putAllExtraParam(Map map) { return this; } + /** + * Add an element to `fleetData` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails#fleetData} for the field documentation. + */ + @SuppressWarnings("unchecked") + public Builder addFleetData(ChargeUpdateParams.PaymentDetails.FleetData element) { + if (this.fleetData == null || this.fleetData instanceof EmptyParam) { + this.fleetData = new ArrayList(); + } + ((List) this.fleetData).add(element); + return this; + } + + /** + * Add all elements to `fleetData` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails#fleetData} for the field documentation. + */ + @SuppressWarnings("unchecked") + public Builder addAllFleetData(List elements) { + if (this.fleetData == null || this.fleetData instanceof EmptyParam) { + this.fleetData = new ArrayList(); + } + ((List) this.fleetData).addAll(elements); + return this; + } + + /** Fleet data for this PaymentIntent. */ + public Builder setFleetData(EmptyParam fleetData) { + this.fleetData = fleetData; + return this; + } + + /** Fleet data for this PaymentIntent. */ + public Builder setFleetData(List fleetData) { + this.fleetData = fleetData; + return this; + } + /** Flight reservation details for this PaymentIntent. */ public Builder setFlight(ChargeUpdateParams.PaymentDetails.Flight flight) { this.flight = flight; @@ -5674,29 +5723,7 @@ public enum Mode implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class Flight { - /** Affiliate details for this purchase. */ - @SerializedName("affiliate") - Affiliate affiliate; - - /** - * The agency number (i.e. International Air Transport Association (IATA) agency number) of - * the travel agency that made the booking. - */ - @SerializedName("agency_number") - Object agencyNumber; - - /** - * The International Air Transport Association (IATA) carrier code of the carrier that issued - * the ticket. - */ - @SerializedName("carrier") - Object carrier; - - /** Delivery details for this purchase. */ - @SerializedName("delivery") - Delivery delivery; - + public static class FleetData { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -5706,41 +5733,27 @@ public static class Flight { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** The name of the person or entity on the reservation. */ - @SerializedName("passenger_name") - Object passengerName; - - /** The details of the passengers in the travel reservation. */ - @SerializedName("passengers") - List passengers; + /** Primary fuel fields for the transaction. */ + @SerializedName("primary_fuel_fields") + PrimaryFuelFields primaryFuelFields; - /** Required. The individual flight segments associated with the trip. */ - @SerializedName("segments") - List segments; + /** Station and acceptor location details. */ + @SerializedName("station") + Station station; - /** The ticket number associated with the travel reservation. */ - @SerializedName("ticket_number") - Object ticketNumber; + /** VAT and Invoice on Behalf (IOB) details. */ + @SerializedName("vat") + Vat vat; - private Flight( - Affiliate affiliate, - Object agencyNumber, - Object carrier, - Delivery delivery, + private FleetData( Map extraParams, - Object passengerName, - List passengers, - List segments, - Object ticketNumber) { - this.affiliate = affiliate; - this.agencyNumber = agencyNumber; - this.carrier = carrier; - this.delivery = delivery; + PrimaryFuelFields primaryFuelFields, + Station station, + Vat vat) { this.extraParams = extraParams; - this.passengerName = passengerName; - this.passengers = passengers; - this.segments = segments; - this.ticketNumber = ticketNumber; + this.primaryFuelFields = primaryFuelFields; + this.station = station; + this.vat = vat; } public static Builder builder() { @@ -5748,90 +5761,24 @@ public static Builder builder() { } public static class Builder { - private Affiliate affiliate; - - private Object agencyNumber; - - private Object carrier; - - private Delivery delivery; - private Map extraParams; - private Object passengerName; - - private List passengers; + private PrimaryFuelFields primaryFuelFields; - private List segments; + private Station station; - private Object ticketNumber; + private Vat vat; /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.Flight build() { - return new ChargeUpdateParams.PaymentDetails.Flight( - this.affiliate, - this.agencyNumber, - this.carrier, - this.delivery, - this.extraParams, - this.passengerName, - this.passengers, - this.segments, - this.ticketNumber); - } - - /** Affiliate details for this purchase. */ - public Builder setAffiliate(ChargeUpdateParams.PaymentDetails.Flight.Affiliate affiliate) { - this.affiliate = affiliate; - return this; - } - - /** - * The agency number (i.e. International Air Transport Association (IATA) agency number) of - * the travel agency that made the booking. - */ - public Builder setAgencyNumber(String agencyNumber) { - this.agencyNumber = agencyNumber; - return this; - } - - /** - * The agency number (i.e. International Air Transport Association (IATA) agency number) of - * the travel agency that made the booking. - */ - public Builder setAgencyNumber(EmptyParam agencyNumber) { - this.agencyNumber = agencyNumber; - return this; - } - - /** - * The International Air Transport Association (IATA) carrier code of the carrier that - * issued the ticket. - */ - public Builder setCarrier(String carrier) { - this.carrier = carrier; - return this; - } - - /** - * The International Air Transport Association (IATA) carrier code of the carrier that - * issued the ticket. - */ - public Builder setCarrier(EmptyParam carrier) { - this.carrier = carrier; - return this; - } - - /** Delivery details for this purchase. */ - public Builder setDelivery(ChargeUpdateParams.PaymentDetails.Flight.Delivery delivery) { - this.delivery = delivery; - return this; + public ChargeUpdateParams.PaymentDetails.FleetData build() { + return new ChargeUpdateParams.PaymentDetails.FleetData( + this.extraParams, this.primaryFuelFields, this.station, this.vat); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Flight#extraParams} for the field + * map. See {@link ChargeUpdateParams.PaymentDetails.FleetData#extraParams} for the field * documentation. */ public Builder putExtraParam(String key, Object value) { @@ -5845,7 +5792,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Flight#extraParams} for the field + * map. See {@link ChargeUpdateParams.PaymentDetails.FleetData#extraParams} for the field * documentation. */ public Builder putAllExtraParam(Map map) { @@ -5856,88 +5803,33 @@ public Builder putAllExtraParam(Map map) { return this; } - /** The name of the person or entity on the reservation. */ - public Builder setPassengerName(String passengerName) { - this.passengerName = passengerName; - return this; - } - - /** The name of the person or entity on the reservation. */ - public Builder setPassengerName(EmptyParam passengerName) { - this.passengerName = passengerName; - return this; - } - - /** - * Add an element to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.Flight#passengers} for the field documentation. - */ - public Builder addPassenger(ChargeUpdateParams.PaymentDetails.Flight.Passenger element) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.add(element); - return this; - } - - /** - * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.Flight#passengers} for the field documentation. - */ - public Builder addAllPassenger( - List elements) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.addAll(elements); - return this; - } - - /** - * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.Flight#segments} for the field documentation. - */ - public Builder addSegment(ChargeUpdateParams.PaymentDetails.Flight.Segment element) { - if (this.segments == null) { - this.segments = new ArrayList<>(); - } - this.segments.add(element); - return this; - } - - /** - * Add all elements to `segments` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.Flight#segments} for the field documentation. - */ - public Builder addAllSegment( - List elements) { - if (this.segments == null) { - this.segments = new ArrayList<>(); - } - this.segments.addAll(elements); + /** Primary fuel fields for the transaction. */ + public Builder setPrimaryFuelFields( + ChargeUpdateParams.PaymentDetails.FleetData.PrimaryFuelFields primaryFuelFields) { + this.primaryFuelFields = primaryFuelFields; return this; } - /** The ticket number associated with the travel reservation. */ - public Builder setTicketNumber(String ticketNumber) { - this.ticketNumber = ticketNumber; + /** Station and acceptor location details. */ + public Builder setStation(ChargeUpdateParams.PaymentDetails.FleetData.Station station) { + this.station = station; return this; } - /** The ticket number associated with the travel reservation. */ - public Builder setTicketNumber(EmptyParam ticketNumber) { - this.ticketNumber = ticketNumber; + /** VAT and Invoice on Behalf (IOB) details. */ + public Builder setVat(ChargeUpdateParams.PaymentDetails.FleetData.Vat vat) { + this.vat = vat; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Affiliate { + public static class PrimaryFuelFields { + /** The fuel brand. */ + @SerializedName("brand") + Brand brand; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -5948,13 +5840,9 @@ public static class Affiliate { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Required. The name of the affiliate that originated the purchase. */ - @SerializedName("name") - Object name; - - private Affiliate(Map extraParams, Object name) { + private PrimaryFuelFields(Brand brand, Map extraParams) { + this.brand = brand; this.extraParams = extraParams; - this.name = name; } public static Builder builder() { @@ -5962,20 +5850,28 @@ public static Builder builder() { } public static class Builder { - private Map extraParams; + private Brand brand; - private Object name; + private Map extraParams; /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.Flight.Affiliate build() { - return new ChargeUpdateParams.PaymentDetails.Flight.Affiliate( - this.extraParams, this.name); + public ChargeUpdateParams.PaymentDetails.FleetData.PrimaryFuelFields build() { + return new ChargeUpdateParams.PaymentDetails.FleetData.PrimaryFuelFields( + this.brand, this.extraParams); + } + + /** The fuel brand. */ + public Builder setBrand( + ChargeUpdateParams.PaymentDetails.FleetData.PrimaryFuelFields.Brand brand) { + this.brand = brand; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Flight.Affiliate#extraParams} for the + * map. See {@link + * ChargeUpdateParams.PaymentDetails.FleetData.PrimaryFuelFields#extraParams} for the * field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -5989,7 +5885,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Flight.Affiliate#extraParams} for the + * map. See {@link + * ChargeUpdateParams.PaymentDetails.FleetData.PrimaryFuelFields#extraParams} for the * field documentation. */ public Builder putAllExtraParam(Map map) { @@ -5999,24 +5896,425 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } + } - /** Required. The name of the affiliate that originated the purchase. */ - public Builder setName(String name) { - this.name = name; - return this; - } + public enum Brand implements ApiRequestParams.EnumParam { + @SerializedName("aafes") + AAFES("aafes"), - /** Required. The name of the affiliate that originated the purchase. */ - public Builder setName(EmptyParam name) { - this.name = name; - return this; - } - } - } + @SerializedName("amerada_hess") + AMERADA_HESS("amerada_hess"), + + @SerializedName("amoco_canada") + AMOCO_CANADA("amoco_canada"), + + @SerializedName("amoco_petroleum_products") + AMOCO_PETROLEUM_PRODUCTS("amoco_petroleum_products"), + + @SerializedName("arco_products") + ARCO_PRODUCTS("arco_products"), + + @SerializedName("asda") + ASDA("asda"), + + @SerializedName("ashland_oil") + ASHLAND_OIL("ashland_oil"), + + @SerializedName("bfl") + BFL("bfl"), + + @SerializedName("bp_mobil") + BP_MOBIL("bp_mobil"), + + @SerializedName("bp_oil") + BP_OIL("bp_oil"), + + @SerializedName("burrnah_major") + BURRNAH_MAJOR("burrnah_major"), + + @SerializedName("butler_arndale") + BUTLER_ARNDALE("butler_arndale"), + + @SerializedName("canadian_tire") + CANADIAN_TIRE("canadian_tire"), + + @SerializedName("canadian_turbo") + CANADIAN_TURBO("canadian_turbo"), + + @SerializedName("caseys_general_store") + CASEYS_GENERAL_STORE("caseys_general_store"), + + @SerializedName("cenex") + CENEX("cenex"), + + @SerializedName("chevron_canada") + CHEVRON_CANADA("chevron_canada"), + + @SerializedName("chevron_usa") + CHEVRON_USA("chevron_usa"), + + @SerializedName("circle_k_stores") + CIRCLE_K_STORES("circle_k_stores"), + + @SerializedName("citgo_petroleum") + CITGO_PETROLEUM("citgo_petroleum"), + + @SerializedName("clark_brands") + CLARK_BRANDS("clark_brands"), + + @SerializedName("conoco_canada") + CONOCO_CANADA("conoco_canada"), + + @SerializedName("conoco_inc") + CONOCO_INC("conoco_inc"), + + @SerializedName("crown_central_petroleum") + CROWN_CENTRAL_PETROLEUM("crown_central_petroleum"), + + @SerializedName("diamond_shamrock_inc") + DIAMOND_SHAMROCK_INC("diamond_shamrock_inc"), + + @SerializedName("discount_tire") + DISCOUNT_TIRE("discount_tire"), + + @SerializedName("domo_gas") + DOMO_GAS("domo_gas"), + + @SerializedName("elf") + ELF("elf"), + + @SerializedName("erickson_oil") + ERICKSON_OIL("erickson_oil"), + + @SerializedName("esso") + ESSO("esso"), + + @SerializedName("esso_canada") + ESSO_CANADA("esso_canada"), + + @SerializedName("exxon") + EXXON("exxon"), + + @SerializedName("exxonmobil") + EXXONMOBIL("exxonmobil"), + + @SerializedName("family_express") + FAMILY_EXPRESS("family_express"), + + @SerializedName("fas_gas_oil") + FAS_GAS_OIL("fas_gas_oil"), + + @SerializedName("federated_coop_sonic") + FEDERATED_COOP_SONIC("federated_coop_sonic"), + + @SerializedName("fina") + FINA("fina"), + + @SerializedName("fina_inc") + FINA_INC("fina_inc"), + + @SerializedName("fkg_oil") + FKG_OIL("fkg_oil"), + + @SerializedName("flare") + FLARE("flare"), + + @SerializedName("flying_j_inc") + FLYING_J_INC("flying_j_inc"), + + @SerializedName("gas_america") + GAS_AMERICA("gas_america"), + + @SerializedName("gate_petroleum") + GATE_PETROLEUM("gate_petroleum"), + + @SerializedName("getty_petroleum") + GETTY_PETROLEUM("getty_petroleum"), + + @SerializedName("giant_eagle") + GIANT_EAGLE("giant_eagle"), + + @SerializedName("grow_mark_inc") + GROW_MARK_INC("grow_mark_inc"), + + @SerializedName("gulf") + GULF("gulf"), + + @SerializedName("gulf_canada") + GULF_CANADA("gulf_canada"), + + @SerializedName("gulf_chevron") + GULF_CHEVRON("gulf_chevron"), + + @SerializedName("handy_way_food") + HANDY_WAY_FOOD("handy_way_food"), + + @SerializedName("heron") + HERON("heron"), + + @SerializedName("holiday_stores") + HOLIDAY_STORES("holiday_stores"), + + @SerializedName("home_depot") + HOME_DEPOT("home_depot"), + + @SerializedName("husky") + HUSKY("husky"), + + @SerializedName("hyvees") + HYVEES("hyvees"), + + @SerializedName("irving") + IRVING("irving"), + + @SerializedName("irving_oil") + IRVING_OIL("irving_oil"), + + @SerializedName("j_sainsbury") + J_SAINSBURY("j_sainsbury"), + + @SerializedName("jet_conoco") + JET_CONOCO("jet_conoco"), + + @SerializedName("krogers") + KROGERS("krogers"), + + @SerializedName("kuwait") + KUWAIT("kuwait"), + + @SerializedName("kwik_trip_inc") + KWIK_TRIP_INC("kwik_trip_inc"), + + @SerializedName("lassus") + LASSUS("lassus"), + + @SerializedName("loves_country_stores") + LOVES_COUNTRY_STORES("loves_country_stores"), + + @SerializedName("mapco_express_inc") + MAPCO_EXPRESS_INC("mapco_express_inc"), + + @SerializedName("marathon_oil") + MARATHON_OIL("marathon_oil"), + + @SerializedName("martin_bailey_inc_dba_hucks") + MARTIN_BAILEY_INC_DBA_HUCKS("martin_bailey_inc_dba_hucks"), + + @SerializedName("maxol") + MAXOL("maxol"), + + @SerializedName("meineke") + MEINEKE("meineke"), + + @SerializedName("mfa") + MFA("mfa"), + + @SerializedName("mohawk") + MOHAWK("mohawk"), + + @SerializedName("mr_gas") + MR_GAS("mr_gas"), + + @SerializedName("murco") + MURCO("murco"), + + @SerializedName("murphy_oil_canada") + MURPHY_OIL_CANADA("murphy_oil_canada"), + + @SerializedName("murphy_oil_usa_inc") + MURPHY_OIL_USA_INC("murphy_oil_usa_inc"), + + @SerializedName("nexcom") + NEXCOM("nexcom"), + + @SerializedName("nordstrom_oil") + NORDSTROM_OIL("nordstrom_oil"), + + @SerializedName("olco") + OLCO("olco"), + + @SerializedName("pdq_store") + PDQ_STORE("pdq_store"), + + @SerializedName("pennzoil_products_inc") + PENNZOIL_PRODUCTS_INC("pennzoil_products_inc"), + + @SerializedName("petro") + PETRO("petro"), + + @SerializedName("petro_canada") + PETRO_CANADA("petro_canada"), + + @SerializedName("petro_t") + PETRO_T("petro_t"), + + @SerializedName("phillips") + PHILLIPS("phillips"), + + @SerializedName("pilot") + PILOT("pilot"), + + @SerializedName("pioneer") + PIONEER("pioneer"), + + @SerializedName("pure_oil") + PURE_OIL("pure_oil"), + + @SerializedName("quaker_state") + QUAKER_STATE("quaker_state"), + + @SerializedName("quarles_oil") + QUARLES_OIL("quarles_oil"), + + @SerializedName("quiktrip") + QUIKTRIP("quiktrip"), + + @SerializedName("racetrac_petroleum_inc") + RACETRAC_PETROLEUM_INC("racetrac_petroleum_inc"), + + @SerializedName("raceway_petroleum") + RACEWAY_PETROLEUM("raceway_petroleum"), + + @SerializedName("repsol") + REPSOL("repsol"), + + @SerializedName("rudy") + RUDY("rudy"), + + @SerializedName("safeway") + SAFEWAY("safeway"), + + @SerializedName("seven_eleven") + SEVEN_ELEVEN("seven_eleven"), + + @SerializedName("sheetz") + SHEETZ("sheetz"), + + @SerializedName("shell") + SHELL("shell"), + + @SerializedName("shell_canada") + SHELL_CANADA("shell_canada"), + + @SerializedName("shell_oil") + SHELL_OIL("shell_oil"), + + @SerializedName("sinclair_oil") + SINCLAIR_OIL("sinclair_oil"), + + @SerializedName("southland_oil") + SOUTHLAND_OIL("southland_oil"), + + @SerializedName("spar") + SPAR("spar"), + + @SerializedName("speedway") + SPEEDWAY("speedway"), + + @SerializedName("sun_company_inc") + SUN_COMPANY_INC("sun_company_inc"), + + @SerializedName("suncor_sunoco_canada") + SUNCOR_SUNOCO_CANADA("suncor_sunoco_canada"), + + @SerializedName("tempo") + TEMPO("tempo"), + + @SerializedName("tesco") + TESCO("tesco"), + + @SerializedName("tesoro_alaska") + TESORO_ALASKA("tesoro_alaska"), + + @SerializedName("texaco") + TEXACO("texaco"), + + @SerializedName("the_pantry_inc") + THE_PANTRY_INC("the_pantry_inc"), + + @SerializedName("thornton_oil") + THORNTON_OIL("thornton_oil"), + + @SerializedName("tosco") + TOSCO("tosco"), + + @SerializedName("total") + TOTAL("total"), + + @SerializedName("travel_centers_of_america") + TRAVEL_CENTERS_OF_AMERICA("travel_centers_of_america"), + + @SerializedName("uk") + UK("uk"), + + @SerializedName("ultramar_canada") + ULTRAMAR_CANADA("ultramar_canada"), + + @SerializedName("unbranded_or_unassigned") + UNBRANDED_OR_UNASSIGNED("unbranded_or_unassigned"), + + @SerializedName("unbranded_unassigned") + UNBRANDED_UNASSIGNED("unbranded_unassigned"), + + @SerializedName("union_76") + UNION_76("union_76"), + + @SerializedName("united_dairy_farmer") + UNITED_DAIRY_FARMER("united_dairy_farmer"), + + @SerializedName("united_refining_kwikfill") + UNITED_REFINING_KWIKFILL("united_refining_kwikfill"), + + @SerializedName("us_oil") + US_OIL("us_oil"), + + @SerializedName("usa_petroleum") + USA_PETROLEUM("usa_petroleum"), + + @SerializedName("valvoline") + VALVOLINE("valvoline"), + + @SerializedName("vg") + VG("vg"), + + @SerializedName("w_morrison") + W_MORRISON("w_morrison"), + + @SerializedName("warren_equities") + WARREN_EQUITIES("warren_equities"), + + @SerializedName("wawa") + WAWA("wawa"), + + @SerializedName("western_energetix") + WESTERN_ENERGETIX("western_energetix"), + + @SerializedName("wilco") + WILCO("wilco"), + + @SerializedName("zions") + ZIONS("zions"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Brand(String value) { + this.value = value; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Station { + /** Additional contact information for the station. */ + @SerializedName("additional_contact_info") + Object additionalContactInfo; + + /** The customer service phone number of the station. */ + @SerializedName("customer_service_phone_number") + Object customerServicePhoneNumber; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Delivery { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -6027,18 +6325,37 @@ public static class Delivery { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** The delivery method for the payment. */ - @SerializedName("mode") - Mode mode; + /** The partner ID code of the station. */ + @SerializedName("partner_id_code") + Object partnerIdCode; - /** Details of the recipient. */ - @SerializedName("recipient") - Recipient recipient; + /** The phone number of the station. */ + @SerializedName("phone_number") + Object phoneNumber; - private Delivery(Map extraParams, Mode mode, Recipient recipient) { + /** The physical location of the station. */ + @SerializedName("service_location") + ServiceLocation serviceLocation; + + /** The URL of the station. */ + @SerializedName("url") + Object url; + + private Station( + Object additionalContactInfo, + Object customerServicePhoneNumber, + Map extraParams, + Object partnerIdCode, + Object phoneNumber, + ServiceLocation serviceLocation, + Object url) { + this.additionalContactInfo = additionalContactInfo; + this.customerServicePhoneNumber = customerServicePhoneNumber; this.extraParams = extraParams; - this.mode = mode; - this.recipient = recipient; + this.partnerIdCode = partnerIdCode; + this.phoneNumber = phoneNumber; + this.serviceLocation = serviceLocation; + this.url = url; } public static Builder builder() { @@ -6046,23 +6363,61 @@ public static Builder builder() { } public static class Builder { + private Object additionalContactInfo; + + private Object customerServicePhoneNumber; + private Map extraParams; - private Mode mode; + private Object partnerIdCode; - private Recipient recipient; + private Object phoneNumber; + + private ServiceLocation serviceLocation; + + private Object url; /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.Flight.Delivery build() { - return new ChargeUpdateParams.PaymentDetails.Flight.Delivery( - this.extraParams, this.mode, this.recipient); + public ChargeUpdateParams.PaymentDetails.FleetData.Station build() { + return new ChargeUpdateParams.PaymentDetails.FleetData.Station( + this.additionalContactInfo, + this.customerServicePhoneNumber, + this.extraParams, + this.partnerIdCode, + this.phoneNumber, + this.serviceLocation, + this.url); + } + + /** Additional contact information for the station. */ + public Builder setAdditionalContactInfo(String additionalContactInfo) { + this.additionalContactInfo = additionalContactInfo; + return this; + } + + /** Additional contact information for the station. */ + public Builder setAdditionalContactInfo(EmptyParam additionalContactInfo) { + this.additionalContactInfo = additionalContactInfo; + return this; + } + + /** The customer service phone number of the station. */ + public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; + } + + /** The customer service phone number of the station. */ + public Builder setCustomerServicePhoneNumber(EmptyParam customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Flight.Delivery#extraParams} for the - * field documentation. + * map. See {@link ChargeUpdateParams.PaymentDetails.FleetData.Station#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -6075,8 +6430,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Flight.Delivery#extraParams} for the - * field documentation. + * map. See {@link ChargeUpdateParams.PaymentDetails.FleetData.Station#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -6086,26 +6441,63 @@ public Builder putAllExtraParam(Map map) { return this; } - /** The delivery method for the payment. */ - public Builder setMode(ChargeUpdateParams.PaymentDetails.Flight.Delivery.Mode mode) { - this.mode = mode; + /** The partner ID code of the station. */ + public Builder setPartnerIdCode(String partnerIdCode) { + this.partnerIdCode = partnerIdCode; return this; } - /** Details of the recipient. */ - public Builder setRecipient( - ChargeUpdateParams.PaymentDetails.Flight.Delivery.Recipient recipient) { - this.recipient = recipient; + /** The partner ID code of the station. */ + public Builder setPartnerIdCode(EmptyParam partnerIdCode) { + this.partnerIdCode = partnerIdCode; + return this; + } + + /** The phone number of the station. */ + public Builder setPhoneNumber(String phoneNumber) { + this.phoneNumber = phoneNumber; + return this; + } + + /** The phone number of the station. */ + public Builder setPhoneNumber(EmptyParam phoneNumber) { + this.phoneNumber = phoneNumber; + return this; + } + + /** The physical location of the station. */ + public Builder setServiceLocation( + ChargeUpdateParams.PaymentDetails.FleetData.Station.ServiceLocation serviceLocation) { + this.serviceLocation = serviceLocation; + return this; + } + + /** The URL of the station. */ + public Builder setUrl(String url) { + this.url = url; + return this; + } + + /** The URL of the station. */ + public Builder setUrl(EmptyParam url) { + this.url = url; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Recipient { - /** The email of the recipient the ticket is delivered to. */ - @SerializedName("email") - Object email; + public static class ServiceLocation { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + Object city; + + /** + * Two-letter country code (ISO + * 3166-1 alpha-2). + */ + @SerializedName("country") + Object country; /** * Map of extra parameters for custom features not available in this client library. The @@ -6117,50 +6509,102 @@ public static class Recipient { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** The name of the recipient the ticket is delivered to. */ - @SerializedName("name") - Object name; - - /** The phone number of the recipient the ticket is delivered to. */ - @SerializedName("phone") - Object phone; + /** + * Required. Address line 1, such as the street, PO Box, or company name. + */ + @SerializedName("line1") + Object line1; - private Recipient( - Object email, Map extraParams, Object name, Object phone) { - this.email = email; - this.extraParams = extraParams; - this.name = name; - this.phone = phone; - } + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + Object line2; - public static Builder builder() { - return new Builder(); - } + /** ZIP or postal code. */ + @SerializedName("postal_code") + Object postalCode; - public static class Builder { - private Object email; + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + Object state; + + private ServiceLocation( + Object city, + Object country, + Map extraParams, + Object line1, + Object line2, + Object postalCode, + Object state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object city; + + private Object country; private Map extraParams; - private Object name; + private Object line1; - private Object phone; + private Object line2; + + private Object postalCode; + + private Object state; /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.Flight.Delivery.Recipient build() { - return new ChargeUpdateParams.PaymentDetails.Flight.Delivery.Recipient( - this.email, this.extraParams, this.name, this.phone); + public ChargeUpdateParams.PaymentDetails.FleetData.Station.ServiceLocation build() { + return new ChargeUpdateParams.PaymentDetails.FleetData.Station.ServiceLocation( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); } - /** The email of the recipient the ticket is delivered to. */ - public Builder setEmail(String email) { - this.email = email; + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; return this; } - /** The email of the recipient the ticket is delivered to. */ - public Builder setEmail(EmptyParam email) { - this.email = email; + /** City, district, suburb, town, or village. */ + public Builder setCity(EmptyParam city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(EmptyParam country) { + this.country = country; return this; } @@ -6168,8 +6612,8 @@ public Builder setEmail(EmptyParam email) { * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeUpdateParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for the - * field documentation. + * ChargeUpdateParams.PaymentDetails.FleetData.Station.ServiceLocation#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -6183,8 +6627,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeUpdateParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for the - * field documentation. + * ChargeUpdateParams.PaymentDetails.FleetData.Station.ServiceLocation#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -6194,57 +6638,72 @@ public Builder putAllExtraParam(Map map) { return this; } - /** The name of the recipient the ticket is delivered to. */ - public Builder setName(String name) { - this.name = name; + /** + * Required. Address line 1, such as the street, PO Box, or company + * name. + */ + public Builder setLine1(String line1) { + this.line1 = line1; return this; } - /** The name of the recipient the ticket is delivered to. */ - public Builder setName(EmptyParam name) { - this.name = name; + /** + * Required. Address line 1, such as the street, PO Box, or company + * name. + */ + public Builder setLine1(EmptyParam line1) { + this.line1 = line1; return this; } - /** The phone number of the recipient the ticket is delivered to. */ - public Builder setPhone(String phone) { - this.phone = phone; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; return this; } - /** The phone number of the recipient the ticket is delivered to. */ - public Builder setPhone(EmptyParam phone) { - this.phone = phone; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(EmptyParam line2) { + this.line2 = line2; return this; } - } - } - - public enum Mode implements ApiRequestParams.EnumParam { - @SerializedName("email") - EMAIL("email"), - - @SerializedName("phone") - PHONE("phone"), - @SerializedName("pickup") - PICKUP("pickup"), + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - @SerializedName("post") - POST("post"); + /** ZIP or postal code. */ + public Builder setPostalCode(EmptyParam postalCode) { + this.postalCode = postalCode; + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } - Mode(String value) { - this.value = value; + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(EmptyParam state) { + this.state = state; + return this; + } } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Passenger { + public static class Vat { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -6256,14 +6715,15 @@ public static class Passenger { Map extraParams; /** - * Required. Full name of the person or entity on the flight reservation. + * Required. Indicates the merchant's agreement for Invoice on Behalf (IOB) + * VAT processing. */ - @SerializedName("name") - Object name; + @SerializedName("iob_indicator") + IobIndicator iobIndicator; - private Passenger(Map extraParams, Object name) { + private Vat(Map extraParams, IobIndicator iobIndicator) { this.extraParams = extraParams; - this.name = name; + this.iobIndicator = iobIndicator; } public static Builder builder() { @@ -6273,18 +6733,18 @@ public static Builder builder() { public static class Builder { private Map extraParams; - private Object name; + private IobIndicator iobIndicator; /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.Flight.Passenger build() { - return new ChargeUpdateParams.PaymentDetails.Flight.Passenger( - this.extraParams, this.name); + public ChargeUpdateParams.PaymentDetails.FleetData.Vat build() { + return new ChargeUpdateParams.PaymentDetails.FleetData.Vat( + this.extraParams, this.iobIndicator); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Flight.Passenger#extraParams} for the + * map. See {@link ChargeUpdateParams.PaymentDetails.FleetData.Vat#extraParams} for the * field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -6298,7 +6758,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Flight.Passenger#extraParams} for the + * map. See {@link ChargeUpdateParams.PaymentDetails.FleetData.Vat#extraParams} for the * field documentation. */ public Builder putAllExtraParam(Map map) { @@ -6310,585 +6770,610 @@ public Builder putAllExtraParam(Map map) { } /** - * Required. Full name of the person or entity on the flight reservation. + * Required. Indicates the merchant's agreement for Invoice on Behalf + * (IOB) VAT processing. */ - public Builder setName(String name) { - this.name = name; + public Builder setIobIndicator( + ChargeUpdateParams.PaymentDetails.FleetData.Vat.IobIndicator iobIndicator) { + this.iobIndicator = iobIndicator; return this; } + } - /** - * Required. Full name of the person or entity on the flight reservation. - */ - public Builder setName(EmptyParam name) { - this.name = name; - return this; + public enum IobIndicator implements ApiRequestParams.EnumParam { + @SerializedName("issuer_to_iob") + ISSUER_TO_IOB("issuer_to_iob"), + + @SerializedName("issuer_to_iob_and_incremental_certification") + ISSUER_TO_IOB_AND_INCREMENTAL_CERTIFICATION( + "issuer_to_iob_and_incremental_certification"), + + @SerializedName("merchant_does_not_agree_to_iob") + MERCHANT_DOES_NOT_AGREE_TO_IOB("merchant_does_not_agree_to_iob"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + IobIndicator(String value) { + this.value = value; } } } + } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Segment { - /** The flight segment amount. */ - @SerializedName("amount") - Long amount; - - /** - * The International Air Transport Association (IATA) airport code for the arrival airport. - */ - @SerializedName("arrival_airport") - Object arrivalAirport; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Flight { + /** Affiliate details for this purchase. */ + @SerializedName("affiliate") + Affiliate affiliate; - /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ - @SerializedName("arrives_at") - Long arrivesAt; + /** + * The agency number (i.e. International Air Transport Association (IATA) agency number) of + * the travel agency that made the booking. + */ + @SerializedName("agency_number") + Object agencyNumber; - /** - * The International Air Transport Association (IATA) carrier code of the carrier operating - * the flight segment. - */ - @SerializedName("carrier") - Object carrier; + /** + * The International Air Transport Association (IATA) carrier code of the carrier that issued + * the ticket. + */ + @SerializedName("carrier") + Object carrier; - /** - * Required. The departure time for the flight segment. Measured in seconds - * since the Unix epoch. - */ - @SerializedName("departs_at") - Long departsAt; + /** Delivery details for this purchase. */ + @SerializedName("delivery") + Delivery delivery; - /** - * The International Air Transport Association (IATA) airport code for the departure - * airport. - */ - @SerializedName("departure_airport") - Object departureAirport; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** The name of the person or entity on the reservation. */ + @SerializedName("passenger_name") + Object passengerName; - /** The flight number associated with the segment. */ - @SerializedName("flight_number") - Object flightNumber; + /** The details of the passengers in the travel reservation. */ + @SerializedName("passengers") + List passengers; - /** The fare class for the segment. */ - @SerializedName("service_class") - ServiceClass serviceClass; + /** Required. The individual flight segments associated with the trip. */ + @SerializedName("segments") + List segments; - private Segment( - Long amount, - Object arrivalAirport, - Long arrivesAt, - Object carrier, - Long departsAt, - Object departureAirport, - Map extraParams, - Object flightNumber, - ServiceClass serviceClass) { - this.amount = amount; - this.arrivalAirport = arrivalAirport; - this.arrivesAt = arrivesAt; - this.carrier = carrier; - this.departsAt = departsAt; - this.departureAirport = departureAirport; - this.extraParams = extraParams; - this.flightNumber = flightNumber; - this.serviceClass = serviceClass; - } + /** The ticket number associated with the travel reservation. */ + @SerializedName("ticket_number") + Object ticketNumber; - public static Builder builder() { - return new Builder(); - } + private Flight( + Affiliate affiliate, + Object agencyNumber, + Object carrier, + Delivery delivery, + Map extraParams, + Object passengerName, + List passengers, + List segments, + Object ticketNumber) { + this.affiliate = affiliate; + this.agencyNumber = agencyNumber; + this.carrier = carrier; + this.delivery = delivery; + this.extraParams = extraParams; + this.passengerName = passengerName; + this.passengers = passengers; + this.segments = segments; + this.ticketNumber = ticketNumber; + } - public static class Builder { - private Long amount; + public static Builder builder() { + return new Builder(); + } - private Object arrivalAirport; + public static class Builder { + private Affiliate affiliate; - private Long arrivesAt; + private Object agencyNumber; - private Object carrier; + private Object carrier; - private Long departsAt; + private Delivery delivery; - private Object departureAirport; + private Map extraParams; - private Map extraParams; + private Object passengerName; - private Object flightNumber; + private List passengers; - private ServiceClass serviceClass; + private List segments; - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.Flight.Segment build() { - return new ChargeUpdateParams.PaymentDetails.Flight.Segment( - this.amount, - this.arrivalAirport, - this.arrivesAt, - this.carrier, - this.departsAt, - this.departureAirport, - this.extraParams, - this.flightNumber, - this.serviceClass); - } + private Object ticketNumber; - /** The flight segment amount. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.Flight build() { + return new ChargeUpdateParams.PaymentDetails.Flight( + this.affiliate, + this.agencyNumber, + this.carrier, + this.delivery, + this.extraParams, + this.passengerName, + this.passengers, + this.segments, + this.ticketNumber); + } - /** - * The International Air Transport Association (IATA) airport code for the arrival - * airport. - */ - public Builder setArrivalAirport(String arrivalAirport) { - this.arrivalAirport = arrivalAirport; - return this; - } + /** Affiliate details for this purchase. */ + public Builder setAffiliate(ChargeUpdateParams.PaymentDetails.Flight.Affiliate affiliate) { + this.affiliate = affiliate; + return this; + } - /** - * The International Air Transport Association (IATA) airport code for the arrival - * airport. - */ - public Builder setArrivalAirport(EmptyParam arrivalAirport) { - this.arrivalAirport = arrivalAirport; - return this; - } + /** + * The agency number (i.e. International Air Transport Association (IATA) agency number) of + * the travel agency that made the booking. + */ + public Builder setAgencyNumber(String agencyNumber) { + this.agencyNumber = agencyNumber; + return this; + } - /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ - public Builder setArrivesAt(Long arrivesAt) { - this.arrivesAt = arrivesAt; - return this; - } + /** + * The agency number (i.e. International Air Transport Association (IATA) agency number) of + * the travel agency that made the booking. + */ + public Builder setAgencyNumber(EmptyParam agencyNumber) { + this.agencyNumber = agencyNumber; + return this; + } - /** - * The International Air Transport Association (IATA) carrier code of the carrier - * operating the flight segment. - */ - public Builder setCarrier(String carrier) { - this.carrier = carrier; - return this; - } + /** + * The International Air Transport Association (IATA) carrier code of the carrier that + * issued the ticket. + */ + public Builder setCarrier(String carrier) { + this.carrier = carrier; + return this; + } - /** - * The International Air Transport Association (IATA) carrier code of the carrier - * operating the flight segment. - */ - public Builder setCarrier(EmptyParam carrier) { - this.carrier = carrier; - return this; - } + /** + * The International Air Transport Association (IATA) carrier code of the carrier that + * issued the ticket. + */ + public Builder setCarrier(EmptyParam carrier) { + this.carrier = carrier; + return this; + } - /** - * Required. The departure time for the flight segment. Measured in - * seconds since the Unix epoch. - */ - public Builder setDepartsAt(Long departsAt) { - this.departsAt = departsAt; - return this; - } + /** Delivery details for this purchase. */ + public Builder setDelivery(ChargeUpdateParams.PaymentDetails.Flight.Delivery delivery) { + this.delivery = delivery; + return this; + } - /** - * The International Air Transport Association (IATA) airport code for the departure - * airport. - */ - public Builder setDepartureAirport(String departureAirport) { - this.departureAirport = departureAirport; - return this; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.Flight#extraParams} for the field + * documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.put(key, value); + return this; + } - /** - * The International Air Transport Association (IATA) airport code for the departure - * airport. - */ - public Builder setDepartureAirport(EmptyParam departureAirport) { - this.departureAirport = departureAirport; - return this; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.Flight#extraParams} for the field + * documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.putAll(map); + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Flight.Segment#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** The name of the person or entity on the reservation. */ + public Builder setPassengerName(String passengerName) { + this.passengerName = passengerName; + return this; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Flight.Segment#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** The name of the person or entity on the reservation. */ + public Builder setPassengerName(EmptyParam passengerName) { + this.passengerName = passengerName; + return this; + } - /** The flight number associated with the segment. */ - public Builder setFlightNumber(String flightNumber) { - this.flightNumber = flightNumber; - return this; + /** + * Add an element to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.Flight#passengers} for the field documentation. + */ + public Builder addPassenger(ChargeUpdateParams.PaymentDetails.Flight.Passenger element) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); } + this.passengers.add(element); + return this; + } - /** The flight number associated with the segment. */ - public Builder setFlightNumber(EmptyParam flightNumber) { - this.flightNumber = flightNumber; - return this; + /** + * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.Flight#passengers} for the field documentation. + */ + public Builder addAllPassenger( + List elements) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); } + this.passengers.addAll(elements); + return this; + } - /** The fare class for the segment. */ - public Builder setServiceClass( - ChargeUpdateParams.PaymentDetails.Flight.Segment.ServiceClass serviceClass) { - this.serviceClass = serviceClass; - return this; + /** + * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.Flight#segments} for the field documentation. + */ + public Builder addSegment(ChargeUpdateParams.PaymentDetails.Flight.Segment element) { + if (this.segments == null) { + this.segments = new ArrayList<>(); } + this.segments.add(element); + return this; } - public enum ServiceClass implements ApiRequestParams.EnumParam { - @SerializedName("business") - BUSINESS("business"), - - @SerializedName("economy") - ECONOMY("economy"), - - @SerializedName("first") - FIRST("first"), - - @SerializedName("premium_economy") - PREMIUM_ECONOMY("premium_economy"); - - @Getter(onMethod_ = {@Override}) - private final String value; - - ServiceClass(String value) { - this.value = value; + /** + * Add all elements to `segments` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.Flight#segments} for the field documentation. + */ + public Builder addAllSegment( + List elements) { + if (this.segments == null) { + this.segments = new ArrayList<>(); } + this.segments.addAll(elements); + return this; } - } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class FlightData { - /** Affiliate details if applicable. */ - @SerializedName("affiliate") - Affiliate affiliate; + /** The ticket number associated with the travel reservation. */ + public Builder setTicketNumber(String ticketNumber) { + this.ticketNumber = ticketNumber; + return this; + } - /** Reservation reference. */ - @SerializedName("booking_number") - Object bookingNumber; + /** The ticket number associated with the travel reservation. */ + public Builder setTicketNumber(EmptyParam ticketNumber) { + this.ticketNumber = ticketNumber; + return this; + } + } - /** Computerized reservation system used to make the reservation and purchase the ticket. */ - @SerializedName("computerized_reservation_system") - Object computerizedReservationSystem; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Affiliate { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Ticket restrictions. */ - @SerializedName("endorsements_and_restrictions") - Object endorsementsAndRestrictions; + /** Required. The name of the affiliate that originated the purchase. */ + @SerializedName("name") + Object name; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) - * name in this param object. Effectively, this map is flattened to its parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private Affiliate(Map extraParams, Object name) { + this.extraParams = extraParams; + this.name = name; + } - /** List of insurances. */ - @SerializedName("insurances") - List insurances; + public static Builder builder() { + return new Builder(); + } - /** List of passengers. */ - @SerializedName("passengers") - List passengers; + public static class Builder { + private Map extraParams; - /** Required. List of flight segments. */ - @SerializedName("segments") - List segments; + private Object name; - /** Electronic ticket indicator. */ - @SerializedName("ticket_electronically_issued_indicator") - Boolean ticketElectronicallyIssuedIndicator; + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.Flight.Affiliate build() { + return new ChargeUpdateParams.PaymentDetails.Flight.Affiliate( + this.extraParams, this.name); + } - /** Required. Total cost breakdown. */ - @SerializedName("total") - Total total; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.Flight.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** Type of flight transaction. */ - @SerializedName("transaction_type") - TransactionType transactionType; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.Flight.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - private FlightData( - Affiliate affiliate, - Object bookingNumber, - Object computerizedReservationSystem, - Object endorsementsAndRestrictions, - Map extraParams, - List insurances, - List passengers, - List segments, - Boolean ticketElectronicallyIssuedIndicator, - Total total, - TransactionType transactionType) { - this.affiliate = affiliate; - this.bookingNumber = bookingNumber; - this.computerizedReservationSystem = computerizedReservationSystem; - this.endorsementsAndRestrictions = endorsementsAndRestrictions; - this.extraParams = extraParams; - this.insurances = insurances; - this.passengers = passengers; - this.segments = segments; - this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; - this.total = total; - this.transactionType = transactionType; - } + /** Required. The name of the affiliate that originated the purchase. */ + public Builder setName(String name) { + this.name = name; + return this; + } - public static Builder builder() { - return new Builder(); + /** Required. The name of the affiliate that originated the purchase. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } + } } - public static class Builder { - private Affiliate affiliate; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Delivery { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private Object bookingNumber; + /** The delivery method for the payment. */ + @SerializedName("mode") + Mode mode; - private Object computerizedReservationSystem; + /** Details of the recipient. */ + @SerializedName("recipient") + Recipient recipient; - private Object endorsementsAndRestrictions; - - private Map extraParams; - - private List insurances; - - private List passengers; - - private List segments; - - private Boolean ticketElectronicallyIssuedIndicator; - - private Total total; - - private TransactionType transactionType; - - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.FlightData build() { - return new ChargeUpdateParams.PaymentDetails.FlightData( - this.affiliate, - this.bookingNumber, - this.computerizedReservationSystem, - this.endorsementsAndRestrictions, - this.extraParams, - this.insurances, - this.passengers, - this.segments, - this.ticketElectronicallyIssuedIndicator, - this.total, - this.transactionType); - } - - /** Affiliate details if applicable. */ - public Builder setAffiliate( - ChargeUpdateParams.PaymentDetails.FlightData.Affiliate affiliate) { - this.affiliate = affiliate; - return this; - } - - /** Reservation reference. */ - public Builder setBookingNumber(String bookingNumber) { - this.bookingNumber = bookingNumber; - return this; - } - - /** Reservation reference. */ - public Builder setBookingNumber(EmptyParam bookingNumber) { - this.bookingNumber = bookingNumber; - return this; + private Delivery(Map extraParams, Mode mode, Recipient recipient) { + this.extraParams = extraParams; + this.mode = mode; + this.recipient = recipient; } - /** Computerized reservation system used to make the reservation and purchase the ticket. */ - public Builder setComputerizedReservationSystem(String computerizedReservationSystem) { - this.computerizedReservationSystem = computerizedReservationSystem; - return this; + public static Builder builder() { + return new Builder(); } - /** Computerized reservation system used to make the reservation and purchase the ticket. */ - public Builder setComputerizedReservationSystem(EmptyParam computerizedReservationSystem) { - this.computerizedReservationSystem = computerizedReservationSystem; - return this; - } + public static class Builder { + private Map extraParams; - /** Ticket restrictions. */ - public Builder setEndorsementsAndRestrictions(String endorsementsAndRestrictions) { - this.endorsementsAndRestrictions = endorsementsAndRestrictions; - return this; - } + private Mode mode; - /** Ticket restrictions. */ - public Builder setEndorsementsAndRestrictions(EmptyParam endorsementsAndRestrictions) { - this.endorsementsAndRestrictions = endorsementsAndRestrictions; - return this; - } + private Recipient recipient; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData#extraParams} for the field - * documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.Flight.Delivery build() { + return new ChargeUpdateParams.PaymentDetails.Flight.Delivery( + this.extraParams, this.mode, this.recipient); } - this.extraParams.put(key, value); - return this; - } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData#extraParams} for the field - * documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.Flight.Delivery#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; } - this.extraParams.putAll(map); - return this; - } - /** - * Add an element to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData#insurances} for the field documentation. - */ - public Builder addInsurance( - ChargeUpdateParams.PaymentDetails.FlightData.Insurance element) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.Flight.Delivery#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; } - this.insurances.add(element); - return this; - } - /** - * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData#insurances} for the field documentation. - */ - public Builder addAllInsurance( - List elements) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); + /** The delivery method for the payment. */ + public Builder setMode(ChargeUpdateParams.PaymentDetails.Flight.Delivery.Mode mode) { + this.mode = mode; + return this; } - this.insurances.addAll(elements); - return this; - } - /** - * Add an element to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData#passengers} for the field documentation. - */ - public Builder addPassenger( - ChargeUpdateParams.PaymentDetails.FlightData.Passenger element) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); + /** Details of the recipient. */ + public Builder setRecipient( + ChargeUpdateParams.PaymentDetails.Flight.Delivery.Recipient recipient) { + this.recipient = recipient; + return this; } - this.passengers.add(element); - return this; } - /** - * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData#passengers} for the field documentation. - */ - public Builder addAllPassenger( - List elements) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.addAll(elements); - return this; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Recipient { + /** The email of the recipient the ticket is delivered to. */ + @SerializedName("email") + Object email; - /** - * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData#segments} for the field documentation. - */ - public Builder addSegment(ChargeUpdateParams.PaymentDetails.FlightData.Segment element) { - if (this.segments == null) { - this.segments = new ArrayList<>(); + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The name of the recipient the ticket is delivered to. */ + @SerializedName("name") + Object name; + + /** The phone number of the recipient the ticket is delivered to. */ + @SerializedName("phone") + Object phone; + + private Recipient( + Object email, Map extraParams, Object name, Object phone) { + this.email = email; + this.extraParams = extraParams; + this.name = name; + this.phone = phone; } - this.segments.add(element); - return this; - } - /** - * Add all elements to `segments` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData#segments} for the field documentation. - */ - public Builder addAllSegment( - List elements) { - if (this.segments == null) { - this.segments = new ArrayList<>(); + public static Builder builder() { + return new Builder(); } - this.segments.addAll(elements); - return this; - } - /** Electronic ticket indicator. */ - public Builder setTicketElectronicallyIssuedIndicator( - Boolean ticketElectronicallyIssuedIndicator) { - this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; - return this; - } + public static class Builder { + private Object email; - /** Required. Total cost breakdown. */ - public Builder setTotal(ChargeUpdateParams.PaymentDetails.FlightData.Total total) { - this.total = total; - return this; - } + private Map extraParams; - /** Type of flight transaction. */ - public Builder setTransactionType( - ChargeUpdateParams.PaymentDetails.FlightData.TransactionType transactionType) { - this.transactionType = transactionType; - return this; + private Object name; + + private Object phone; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.Flight.Delivery.Recipient build() { + return new ChargeUpdateParams.PaymentDetails.Flight.Delivery.Recipient( + this.email, this.extraParams, this.name, this.phone); + } + + /** The email of the recipient the ticket is delivered to. */ + public Builder setEmail(String email) { + this.email = email; + return this; + } + + /** The email of the recipient the ticket is delivered to. */ + public Builder setEmail(EmptyParam email) { + this.email = email; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The name of the recipient the ticket is delivered to. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** The name of the recipient the ticket is delivered to. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } + + /** The phone number of the recipient the ticket is delivered to. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } + + /** The phone number of the recipient the ticket is delivered to. */ + public Builder setPhone(EmptyParam phone) { + this.phone = phone; + return this; + } + } + } + + public enum Mode implements ApiRequestParams.EnumParam { + @SerializedName("email") + EMAIL("email"), + + @SerializedName("phone") + PHONE("phone"), + + @SerializedName("pickup") + PICKUP("pickup"), + + @SerializedName("post") + POST("post"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Mode(String value) { + this.value = value; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Affiliate { - /** Affiliate partner code. */ - @SerializedName("code") - Object code; - + public static class Passenger { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -6899,23 +7384,15 @@ public static class Affiliate { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Name of affiliate partner. */ + /** + * Required. Full name of the person or entity on the flight reservation. + */ @SerializedName("name") Object name; - /** Code provided by the company to a travel agent authorizing ticket issuance. */ - @SerializedName("travel_authorization_code") - Object travelAuthorizationCode; - - private Affiliate( - Object code, - Map extraParams, - Object name, - Object travelAuthorizationCode) { - this.code = code; + private Passenger(Map extraParams, Object name) { this.extraParams = extraParams; this.name = name; - this.travelAuthorizationCode = travelAuthorizationCode; } public static Builder builder() { @@ -6923,37 +7400,21 @@ public static Builder builder() { } public static class Builder { - private Object code; - private Map extraParams; private Object name; - private Object travelAuthorizationCode; - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.FlightData.Affiliate build() { - return new ChargeUpdateParams.PaymentDetails.FlightData.Affiliate( - this.code, this.extraParams, this.name, this.travelAuthorizationCode); - } - - /** Affiliate partner code. */ - public Builder setCode(String code) { - this.code = code; - return this; - } - - /** Affiliate partner code. */ - public Builder setCode(EmptyParam code) { - this.code = code; - return this; + public ChargeUpdateParams.PaymentDetails.Flight.Passenger build() { + return new ChargeUpdateParams.PaymentDetails.Flight.Passenger( + this.extraParams, this.name); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Affiliate#extraParams} for - * the field documentation. + * map. See {@link ChargeUpdateParams.PaymentDetails.Flight.Passenger#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -6966,8 +7427,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Affiliate#extraParams} for - * the field documentation. + * map. See {@link ChargeUpdateParams.PaymentDetails.Flight.Passenger#extraParams} for the + * field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -6977,42 +7438,61 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Name of affiliate partner. */ + /** + * Required. Full name of the person or entity on the flight reservation. + */ public Builder setName(String name) { this.name = name; return this; } - /** Name of affiliate partner. */ + /** + * Required. Full name of the person or entity on the flight reservation. + */ public Builder setName(EmptyParam name) { this.name = name; return this; } - - /** Code provided by the company to a travel agent authorizing ticket issuance. */ - public Builder setTravelAuthorizationCode(String travelAuthorizationCode) { - this.travelAuthorizationCode = travelAuthorizationCode; - return this; - } - - /** Code provided by the company to a travel agent authorizing ticket issuance. */ - public Builder setTravelAuthorizationCode(EmptyParam travelAuthorizationCode) { - this.travelAuthorizationCode = travelAuthorizationCode; - return this; - } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Insurance { - /** Required. Insurance cost. */ + public static class Segment { + /** The flight segment amount. */ @SerializedName("amount") Long amount; - /** Insurance currency. */ - @SerializedName("currency") - Object currency; + /** + * The International Air Transport Association (IATA) airport code for the arrival airport. + */ + @SerializedName("arrival_airport") + Object arrivalAirport; + + /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ + @SerializedName("arrives_at") + Long arrivesAt; + + /** + * The International Air Transport Association (IATA) carrier code of the carrier operating + * the flight segment. + */ + @SerializedName("carrier") + Object carrier; + + /** + * Required. The departure time for the flight segment. Measured in seconds + * since the Unix epoch. + */ + @SerializedName("departs_at") + Long departsAt; + + /** + * The International Air Transport Association (IATA) airport code for the departure + * airport. + */ + @SerializedName("departure_airport") + Object departureAirport; /** * Map of extra parameters for custom features not available in this client library. The @@ -7024,25 +7504,33 @@ public static class Insurance { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Insurance company name. */ - @SerializedName("insurance_company_name") - Object insuranceCompanyName; + /** The flight number associated with the segment. */ + @SerializedName("flight_number") + Object flightNumber; - /** Required. Type of insurance. */ - @SerializedName("insurance_type") - InsuranceType insuranceType; + /** The fare class for the segment. */ + @SerializedName("service_class") + ServiceClass serviceClass; - private Insurance( + private Segment( Long amount, - Object currency, + Object arrivalAirport, + Long arrivesAt, + Object carrier, + Long departsAt, + Object departureAirport, Map extraParams, - Object insuranceCompanyName, - InsuranceType insuranceType) { + Object flightNumber, + ServiceClass serviceClass) { this.amount = amount; - this.currency = currency; + this.arrivalAirport = arrivalAirport; + this.arrivesAt = arrivesAt; + this.carrier = carrier; + this.departsAt = departsAt; + this.departureAirport = departureAirport; this.extraParams = extraParams; - this.insuranceCompanyName = insuranceCompanyName; - this.insuranceType = insuranceType; + this.flightNumber = flightNumber; + this.serviceClass = serviceClass; } public static Builder builder() { @@ -7052,157 +7540,116 @@ public static Builder builder() { public static class Builder { private Long amount; - private Object currency; + private Object arrivalAirport; - private Map extraParams; + private Long arrivesAt; - private Object insuranceCompanyName; + private Object carrier; - private InsuranceType insuranceType; + private Long departsAt; - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.FlightData.Insurance build() { - return new ChargeUpdateParams.PaymentDetails.FlightData.Insurance( - this.amount, - this.currency, + private Object departureAirport; + + private Map extraParams; + + private Object flightNumber; + + private ServiceClass serviceClass; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.Flight.Segment build() { + return new ChargeUpdateParams.PaymentDetails.Flight.Segment( + this.amount, + this.arrivalAirport, + this.arrivesAt, + this.carrier, + this.departsAt, + this.departureAirport, this.extraParams, - this.insuranceCompanyName, - this.insuranceType); + this.flightNumber, + this.serviceClass); } - /** Required. Insurance cost. */ + /** The flight segment amount. */ public Builder setAmount(Long amount) { this.amount = amount; return this; } - /** Insurance currency. */ - public Builder setCurrency(String currency) { - this.currency = currency; + /** + * The International Air Transport Association (IATA) airport code for the arrival + * airport. + */ + public Builder setArrivalAirport(String arrivalAirport) { + this.arrivalAirport = arrivalAirport; return this; } - /** Insurance currency. */ - public Builder setCurrency(EmptyParam currency) { - this.currency = currency; + /** + * The International Air Transport Association (IATA) airport code for the arrival + * airport. + */ + public Builder setArrivalAirport(EmptyParam arrivalAirport) { + this.arrivalAirport = arrivalAirport; return this; } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Insurance#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); + /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ + public Builder setArrivesAt(Long arrivesAt) { + this.arrivesAt = arrivesAt; return this; } /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Insurance#extraParams} for - * the field documentation. + * The International Air Transport Association (IATA) carrier code of the carrier + * operating the flight segment. */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); + public Builder setCarrier(String carrier) { + this.carrier = carrier; return this; } - /** Insurance company name. */ - public Builder setInsuranceCompanyName(String insuranceCompanyName) { - this.insuranceCompanyName = insuranceCompanyName; + /** + * The International Air Transport Association (IATA) carrier code of the carrier + * operating the flight segment. + */ + public Builder setCarrier(EmptyParam carrier) { + this.carrier = carrier; return this; } - /** Insurance company name. */ - public Builder setInsuranceCompanyName(EmptyParam insuranceCompanyName) { - this.insuranceCompanyName = insuranceCompanyName; + /** + * Required. The departure time for the flight segment. Measured in + * seconds since the Unix epoch. + */ + public Builder setDepartsAt(Long departsAt) { + this.departsAt = departsAt; return this; } - /** Required. Type of insurance. */ - public Builder setInsuranceType( - ChargeUpdateParams.PaymentDetails.FlightData.Insurance.InsuranceType insuranceType) { - this.insuranceType = insuranceType; + /** + * The International Air Transport Association (IATA) airport code for the departure + * airport. + */ + public Builder setDepartureAirport(String departureAirport) { + this.departureAirport = departureAirport; return this; } - } - - public enum InsuranceType implements ApiRequestParams.EnumParam { - @SerializedName("baggage") - BAGGAGE("baggage"), - - @SerializedName("bankruptcy") - BANKRUPTCY("bankruptcy"), - - @SerializedName("cancelation") - CANCELATION("cancelation"), - - @SerializedName("emergency") - EMERGENCY("emergency"), - - @SerializedName("medical") - MEDICAL("medical"); - - @Getter(onMethod_ = {@Override}) - private final String value; - - InsuranceType(String value) { - this.value = value; - } - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Passenger { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; - - /** Required. Passenger's full name. */ - @SerializedName("name") - Object name; - - private Passenger(Map extraParams, Object name) { - this.extraParams = extraParams; - this.name = name; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private Map extraParams; - private Object name; - - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.FlightData.Passenger build() { - return new ChargeUpdateParams.PaymentDetails.FlightData.Passenger( - this.extraParams, this.name); + /** + * The International Air Transport Association (IATA) airport code for the departure + * airport. + */ + public Builder setDepartureAirport(EmptyParam departureAirport) { + this.departureAirport = departureAirport; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Passenger#extraParams} for - * the field documentation. + * map. See {@link ChargeUpdateParams.PaymentDetails.Flight.Segment#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -7215,8 +7662,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Passenger#extraParams} for - * the field documentation. + * map. See {@link ChargeUpdateParams.PaymentDetails.Flight.Segment#extraParams} for the + * field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -7226,258 +7673,415 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Required. Passenger's full name. */ - public Builder setName(String name) { - this.name = name; + /** The flight number associated with the segment. */ + public Builder setFlightNumber(String flightNumber) { + this.flightNumber = flightNumber; return this; } - /** Required. Passenger's full name. */ - public Builder setName(EmptyParam name) { - this.name = name; + /** The flight number associated with the segment. */ + public Builder setFlightNumber(EmptyParam flightNumber) { + this.flightNumber = flightNumber; return this; } - } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Segment { - /** Segment fare amount. */ - @SerializedName("amount") - Long amount; + /** The fare class for the segment. */ + public Builder setServiceClass( + ChargeUpdateParams.PaymentDetails.Flight.Segment.ServiceClass serviceClass) { + this.serviceClass = serviceClass; + return this; + } + } - /** Required. Arrival details. */ - @SerializedName("arrival") - Arrival arrival; + public enum ServiceClass implements ApiRequestParams.EnumParam { + @SerializedName("business") + BUSINESS("business"), - /** Required. Airline carrier code. */ - @SerializedName("carrier_code") - Object carrierCode; + @SerializedName("economy") + ECONOMY("economy"), - /** Carrier name. */ - @SerializedName("carrier_name") - Object carrierName; + @SerializedName("first") + FIRST("first"), - /** Segment currency. */ - @SerializedName("currency") - Object currency; + @SerializedName("premium_economy") + PREMIUM_ECONOMY("premium_economy"); - /** Required. Departure details. */ - @SerializedName("departure") - Departure departure; + @Getter(onMethod_ = {@Override}) + private final String value; - /** Exchange ticket number. */ - @SerializedName("exchange_ticket_number") - Object exchangeTicketNumber; + ServiceClass(String value) { + this.value = value; + } + } + } + } - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class FlightData { + /** Affiliate details if applicable. */ + @SerializedName("affiliate") + Affiliate affiliate; - /** Fare basis code. */ - @SerializedName("fare_basis_code") - Object fareBasisCode; + /** Reservation reference. */ + @SerializedName("booking_number") + Object bookingNumber; - /** Additional fees. */ - @SerializedName("fees") - Long fees; + /** Computerized reservation system used to make the reservation and purchase the ticket. */ + @SerializedName("computerized_reservation_system") + Object computerizedReservationSystem; - /** Flight number. */ - @SerializedName("flight_number") - Object flightNumber; + /** Ticket restrictions. */ + @SerializedName("endorsements_and_restrictions") + Object endorsementsAndRestrictions; - /** Stopover indicator. */ - @SerializedName("is_stop_over_indicator") - Boolean isStopOverIndicator; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Refundable ticket indicator. */ - @SerializedName("refundable") - Boolean refundable; + /** List of insurances. */ + @SerializedName("insurances") + List insurances; - /** Required. Class of service. */ - @SerializedName("service_class") - ServiceClass serviceClass; + /** List of passengers. */ + @SerializedName("passengers") + List passengers; - /** Tax amount for segment. */ - @SerializedName("tax_amount") - Long taxAmount; + /** Required. List of flight segments. */ + @SerializedName("segments") + List segments; - /** Ticket number. */ - @SerializedName("ticket_number") - Object ticketNumber; + /** Electronic ticket indicator. */ + @SerializedName("ticket_electronically_issued_indicator") + Boolean ticketElectronicallyIssuedIndicator; - private Segment( - Long amount, - Arrival arrival, - Object carrierCode, - Object carrierName, - Object currency, - Departure departure, - Object exchangeTicketNumber, - Map extraParams, - Object fareBasisCode, - Long fees, - Object flightNumber, - Boolean isStopOverIndicator, - Boolean refundable, - ServiceClass serviceClass, - Long taxAmount, - Object ticketNumber) { - this.amount = amount; - this.arrival = arrival; - this.carrierCode = carrierCode; - this.carrierName = carrierName; - this.currency = currency; - this.departure = departure; - this.exchangeTicketNumber = exchangeTicketNumber; - this.extraParams = extraParams; - this.fareBasisCode = fareBasisCode; - this.fees = fees; - this.flightNumber = flightNumber; - this.isStopOverIndicator = isStopOverIndicator; - this.refundable = refundable; - this.serviceClass = serviceClass; - this.taxAmount = taxAmount; - this.ticketNumber = ticketNumber; - } + /** Required. Total cost breakdown. */ + @SerializedName("total") + Total total; - public static Builder builder() { - return new Builder(); - } + /** Type of flight transaction. */ + @SerializedName("transaction_type") + TransactionType transactionType; - public static class Builder { - private Long amount; + private FlightData( + Affiliate affiliate, + Object bookingNumber, + Object computerizedReservationSystem, + Object endorsementsAndRestrictions, + Map extraParams, + List insurances, + List passengers, + List segments, + Boolean ticketElectronicallyIssuedIndicator, + Total total, + TransactionType transactionType) { + this.affiliate = affiliate; + this.bookingNumber = bookingNumber; + this.computerizedReservationSystem = computerizedReservationSystem; + this.endorsementsAndRestrictions = endorsementsAndRestrictions; + this.extraParams = extraParams; + this.insurances = insurances; + this.passengers = passengers; + this.segments = segments; + this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; + this.total = total; + this.transactionType = transactionType; + } - private Arrival arrival; + public static Builder builder() { + return new Builder(); + } - private Object carrierCode; + public static class Builder { + private Affiliate affiliate; - private Object carrierName; + private Object bookingNumber; - private Object currency; + private Object computerizedReservationSystem; - private Departure departure; + private Object endorsementsAndRestrictions; - private Object exchangeTicketNumber; + private Map extraParams; - private Map extraParams; + private List insurances; - private Object fareBasisCode; + private List passengers; - private Long fees; + private List segments; - private Object flightNumber; + private Boolean ticketElectronicallyIssuedIndicator; - private Boolean isStopOverIndicator; + private Total total; - private Boolean refundable; + private TransactionType transactionType; - private ServiceClass serviceClass; + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.FlightData build() { + return new ChargeUpdateParams.PaymentDetails.FlightData( + this.affiliate, + this.bookingNumber, + this.computerizedReservationSystem, + this.endorsementsAndRestrictions, + this.extraParams, + this.insurances, + this.passengers, + this.segments, + this.ticketElectronicallyIssuedIndicator, + this.total, + this.transactionType); + } - private Long taxAmount; + /** Affiliate details if applicable. */ + public Builder setAffiliate( + ChargeUpdateParams.PaymentDetails.FlightData.Affiliate affiliate) { + this.affiliate = affiliate; + return this; + } - private Object ticketNumber; + /** Reservation reference. */ + public Builder setBookingNumber(String bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.FlightData.Segment build() { - return new ChargeUpdateParams.PaymentDetails.FlightData.Segment( - this.amount, - this.arrival, - this.carrierCode, - this.carrierName, - this.currency, - this.departure, - this.exchangeTicketNumber, - this.extraParams, - this.fareBasisCode, - this.fees, - this.flightNumber, - this.isStopOverIndicator, - this.refundable, - this.serviceClass, - this.taxAmount, - this.ticketNumber); - } + /** Reservation reference. */ + public Builder setBookingNumber(EmptyParam bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } - /** Segment fare amount. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + /** Computerized reservation system used to make the reservation and purchase the ticket. */ + public Builder setComputerizedReservationSystem(String computerizedReservationSystem) { + this.computerizedReservationSystem = computerizedReservationSystem; + return this; + } - /** Required. Arrival details. */ - public Builder setArrival( - ChargeUpdateParams.PaymentDetails.FlightData.Segment.Arrival arrival) { - this.arrival = arrival; - return this; - } + /** Computerized reservation system used to make the reservation and purchase the ticket. */ + public Builder setComputerizedReservationSystem(EmptyParam computerizedReservationSystem) { + this.computerizedReservationSystem = computerizedReservationSystem; + return this; + } - /** Required. Airline carrier code. */ - public Builder setCarrierCode(String carrierCode) { - this.carrierCode = carrierCode; - return this; - } + /** Ticket restrictions. */ + public Builder setEndorsementsAndRestrictions(String endorsementsAndRestrictions) { + this.endorsementsAndRestrictions = endorsementsAndRestrictions; + return this; + } - /** Required. Airline carrier code. */ - public Builder setCarrierCode(EmptyParam carrierCode) { - this.carrierCode = carrierCode; - return this; - } + /** Ticket restrictions. */ + public Builder setEndorsementsAndRestrictions(EmptyParam endorsementsAndRestrictions) { + this.endorsementsAndRestrictions = endorsementsAndRestrictions; + return this; + } - /** Carrier name. */ - public Builder setCarrierName(String carrierName) { - this.carrierName = carrierName; - return this; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData#extraParams} for the field + * documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.put(key, value); + return this; + } - /** Carrier name. */ - public Builder setCarrierName(EmptyParam carrierName) { - this.carrierName = carrierName; - return this; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData#extraParams} for the field + * documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.putAll(map); + return this; + } - /** Segment currency. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; + /** + * Add an element to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData#insurances} for the field documentation. + */ + public Builder addInsurance( + ChargeUpdateParams.PaymentDetails.FlightData.Insurance element) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); } + this.insurances.add(element); + return this; + } - /** Segment currency. */ - public Builder setCurrency(EmptyParam currency) { - this.currency = currency; - return this; + /** + * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData#insurances} for the field documentation. + */ + public Builder addAllInsurance( + List elements) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); } + this.insurances.addAll(elements); + return this; + } - /** Required. Departure details. */ - public Builder setDeparture( - ChargeUpdateParams.PaymentDetails.FlightData.Segment.Departure departure) { - this.departure = departure; - return this; + /** + * Add an element to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData#passengers} for the field documentation. + */ + public Builder addPassenger( + ChargeUpdateParams.PaymentDetails.FlightData.Passenger element) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); } + this.passengers.add(element); + return this; + } - /** Exchange ticket number. */ - public Builder setExchangeTicketNumber(String exchangeTicketNumber) { - this.exchangeTicketNumber = exchangeTicketNumber; + /** + * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData#passengers} for the field documentation. + */ + public Builder addAllPassenger( + List elements) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.addAll(elements); + return this; + } + + /** + * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData#segments} for the field documentation. + */ + public Builder addSegment(ChargeUpdateParams.PaymentDetails.FlightData.Segment element) { + if (this.segments == null) { + this.segments = new ArrayList<>(); + } + this.segments.add(element); + return this; + } + + /** + * Add all elements to `segments` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData#segments} for the field documentation. + */ + public Builder addAllSegment( + List elements) { + if (this.segments == null) { + this.segments = new ArrayList<>(); + } + this.segments.addAll(elements); + return this; + } + + /** Electronic ticket indicator. */ + public Builder setTicketElectronicallyIssuedIndicator( + Boolean ticketElectronicallyIssuedIndicator) { + this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; + return this; + } + + /** Required. Total cost breakdown. */ + public Builder setTotal(ChargeUpdateParams.PaymentDetails.FlightData.Total total) { + this.total = total; + return this; + } + + /** Type of flight transaction. */ + public Builder setTransactionType( + ChargeUpdateParams.PaymentDetails.FlightData.TransactionType transactionType) { + this.transactionType = transactionType; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Affiliate { + /** Affiliate partner code. */ + @SerializedName("code") + Object code; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Name of affiliate partner. */ + @SerializedName("name") + Object name; + + /** Code provided by the company to a travel agent authorizing ticket issuance. */ + @SerializedName("travel_authorization_code") + Object travelAuthorizationCode; + + private Affiliate( + Object code, + Map extraParams, + Object name, + Object travelAuthorizationCode) { + this.code = code; + this.extraParams = extraParams; + this.name = name; + this.travelAuthorizationCode = travelAuthorizationCode; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object code; + + private Map extraParams; + + private Object name; + + private Object travelAuthorizationCode; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.FlightData.Affiliate build() { + return new ChargeUpdateParams.PaymentDetails.FlightData.Affiliate( + this.code, this.extraParams, this.name, this.travelAuthorizationCode); + } + + /** Affiliate partner code. */ + public Builder setCode(String code) { + this.code = code; return this; } - /** Exchange ticket number. */ - public Builder setExchangeTicketNumber(EmptyParam exchangeTicketNumber) { - this.exchangeTicketNumber = exchangeTicketNumber; + /** Affiliate partner code. */ + public Builder setCode(EmptyParam code) { + this.code = code; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Segment#extraParams} for + * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Affiliate#extraParams} for * the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -7491,7 +8095,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Segment#extraParams} for + * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Affiliate#extraParams} for * the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -7502,392 +8106,1997 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Fare basis code. */ - public Builder setFareBasisCode(String fareBasisCode) { - this.fareBasisCode = fareBasisCode; + /** Name of affiliate partner. */ + public Builder setName(String name) { + this.name = name; return this; } - /** Fare basis code. */ - public Builder setFareBasisCode(EmptyParam fareBasisCode) { - this.fareBasisCode = fareBasisCode; + /** Name of affiliate partner. */ + public Builder setName(EmptyParam name) { + this.name = name; return this; } - /** Additional fees. */ - public Builder setFees(Long fees) { - this.fees = fees; + /** Code provided by the company to a travel agent authorizing ticket issuance. */ + public Builder setTravelAuthorizationCode(String travelAuthorizationCode) { + this.travelAuthorizationCode = travelAuthorizationCode; return this; } - /** Flight number. */ - public Builder setFlightNumber(String flightNumber) { - this.flightNumber = flightNumber; + /** Code provided by the company to a travel agent authorizing ticket issuance. */ + public Builder setTravelAuthorizationCode(EmptyParam travelAuthorizationCode) { + this.travelAuthorizationCode = travelAuthorizationCode; return this; } + } + } - /** Flight number. */ - public Builder setFlightNumber(EmptyParam flightNumber) { - this.flightNumber = flightNumber; - return this; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Insurance { + /** Required. Insurance cost. */ + @SerializedName("amount") + Long amount; - /** Stopover indicator. */ - public Builder setIsStopOverIndicator(Boolean isStopOverIndicator) { - this.isStopOverIndicator = isStopOverIndicator; - return this; - } + /** Insurance currency. */ + @SerializedName("currency") + Object currency; - /** Refundable ticket indicator. */ - public Builder setRefundable(Boolean refundable) { - this.refundable = refundable; - return this; - } + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Required. Class of service. */ - public Builder setServiceClass( - ChargeUpdateParams.PaymentDetails.FlightData.Segment.ServiceClass serviceClass) { - this.serviceClass = serviceClass; - return this; + /** Insurance company name. */ + @SerializedName("insurance_company_name") + Object insuranceCompanyName; + + /** Required. Type of insurance. */ + @SerializedName("insurance_type") + InsuranceType insuranceType; + + private Insurance( + Long amount, + Object currency, + Map extraParams, + Object insuranceCompanyName, + InsuranceType insuranceType) { + this.amount = amount; + this.currency = currency; + this.extraParams = extraParams; + this.insuranceCompanyName = insuranceCompanyName; + this.insuranceType = insuranceType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private Object currency; + + private Map extraParams; + + private Object insuranceCompanyName; + + private InsuranceType insuranceType; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.FlightData.Insurance build() { + return new ChargeUpdateParams.PaymentDetails.FlightData.Insurance( + this.amount, + this.currency, + this.extraParams, + this.insuranceCompanyName, + this.insuranceType); } - /** Tax amount for segment. */ - public Builder setTaxAmount(Long taxAmount) { - this.taxAmount = taxAmount; + /** Required. Insurance cost. */ + public Builder setAmount(Long amount) { + this.amount = amount; return this; } - /** Ticket number. */ - public Builder setTicketNumber(String ticketNumber) { - this.ticketNumber = ticketNumber; + /** Insurance currency. */ + public Builder setCurrency(String currency) { + this.currency = currency; return this; } - /** Ticket number. */ - public Builder setTicketNumber(EmptyParam ticketNumber) { - this.ticketNumber = ticketNumber; + /** Insurance currency. */ + public Builder setCurrency(EmptyParam currency) { + this.currency = currency; return this; } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Arrival { - /** Required. Arrival airport IATA code. */ - @SerializedName("airport") - Object airport; - - /** Arrival date/time. */ - @SerializedName("arrives_at") - Long arrivesAt; - - /** Arrival city. */ - @SerializedName("city") - Object city; - /** Arrival country. */ - @SerializedName("country") - Object country; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Insurance#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Insurance#extraParams} for + * the field documentation. */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - private Arrival( - Object airport, - Long arrivesAt, - Object city, - Object country, - Map extraParams) { - this.airport = airport; - this.arrivesAt = arrivesAt; - this.city = city; - this.country = country; - this.extraParams = extraParams; + /** Insurance company name. */ + public Builder setInsuranceCompanyName(String insuranceCompanyName) { + this.insuranceCompanyName = insuranceCompanyName; + return this; } - public static Builder builder() { - return new Builder(); + /** Insurance company name. */ + public Builder setInsuranceCompanyName(EmptyParam insuranceCompanyName) { + this.insuranceCompanyName = insuranceCompanyName; + return this; } - public static class Builder { - private Object airport; + /** Required. Type of insurance. */ + public Builder setInsuranceType( + ChargeUpdateParams.PaymentDetails.FlightData.Insurance.InsuranceType insuranceType) { + this.insuranceType = insuranceType; + return this; + } + } - private Long arrivesAt; + public enum InsuranceType implements ApiRequestParams.EnumParam { + @SerializedName("baggage") + BAGGAGE("baggage"), - private Object city; + @SerializedName("bankruptcy") + BANKRUPTCY("bankruptcy"), - private Object country; + @SerializedName("cancelation") + CANCELATION("cancelation"), - private Map extraParams; + @SerializedName("emergency") + EMERGENCY("emergency"), - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.FlightData.Segment.Arrival build() { - return new ChargeUpdateParams.PaymentDetails.FlightData.Segment.Arrival( - this.airport, this.arrivesAt, this.city, this.country, this.extraParams); - } + @SerializedName("medical") + MEDICAL("medical"); - /** Required. Arrival airport IATA code. */ - public Builder setAirport(String airport) { - this.airport = airport; - return this; - } + @Getter(onMethod_ = {@Override}) + private final String value; - /** Required. Arrival airport IATA code. */ - public Builder setAirport(EmptyParam airport) { - this.airport = airport; - return this; - } + InsuranceType(String value) { + this.value = value; + } + } + } - /** Arrival date/time. */ - public Builder setArrivesAt(Long arrivesAt) { - this.arrivesAt = arrivesAt; - return this; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Passenger { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Arrival city. */ - public Builder setCity(String city) { - this.city = city; - return this; - } + /** Required. Passenger's full name. */ + @SerializedName("name") + Object name; - /** Arrival city. */ - public Builder setCity(EmptyParam city) { - this.city = city; - return this; - } + private Passenger(Map extraParams, Object name) { + this.extraParams = extraParams; + this.name = name; + } - /** Arrival country. */ - public Builder setCountry(String country) { - this.country = country; - return this; - } + public static Builder builder() { + return new Builder(); + } - /** Arrival country. */ - public Builder setCountry(EmptyParam country) { - this.country = country; - return this; - } + public static class Builder { + private Map extraParams; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData.Segment.Arrival#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + private Object name; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData.Segment.Arrival#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.FlightData.Passenger build() { + return new ChargeUpdateParams.PaymentDetails.FlightData.Passenger( + this.extraParams, this.name); } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Departure { - /** Required. Departure airport IATA code. */ - @SerializedName("airport") - Object airport; - - /** Departure city. */ - @SerializedName("city") - Object city; - - /** Departure country. */ - @SerializedName("country") - Object country; - /** Required. Departure date/time. */ - @SerializedName("departs_at") - Long departsAt; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Passenger#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Passenger#extraParams} for + * the field documentation. */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - private Departure( - Object airport, - Object city, - Object country, - Long departsAt, - Map extraParams) { - this.airport = airport; - this.city = city; - this.country = country; - this.departsAt = departsAt; - this.extraParams = extraParams; + /** Required. Passenger's full name. */ + public Builder setName(String name) { + this.name = name; + return this; } - public static Builder builder() { - return new Builder(); + /** Required. Passenger's full name. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; } + } + } - public static class Builder { - private Object airport; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Segment { + /** Segment fare amount. */ + @SerializedName("amount") + Long amount; - private Object city; + /** Required. Arrival details. */ + @SerializedName("arrival") + Arrival arrival; - private Object country; + /** Required. Airline carrier code. */ + @SerializedName("carrier_code") + Object carrierCode; - private Long departsAt; + /** Carrier name. */ + @SerializedName("carrier_name") + Object carrierName; - private Map extraParams; + /** Segment currency. */ + @SerializedName("currency") + Object currency; - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.FlightData.Segment.Departure build() { - return new ChargeUpdateParams.PaymentDetails.FlightData.Segment.Departure( - this.airport, this.city, this.country, this.departsAt, this.extraParams); - } + /** Required. Departure details. */ + @SerializedName("departure") + Departure departure; - /** Required. Departure airport IATA code. */ - public Builder setAirport(String airport) { - this.airport = airport; - return this; - } + /** Exchange ticket number. */ + @SerializedName("exchange_ticket_number") + Object exchangeTicketNumber; - /** Required. Departure airport IATA code. */ - public Builder setAirport(EmptyParam airport) { - this.airport = airport; - return this; - } + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Departure city. */ - public Builder setCity(String city) { - this.city = city; - return this; - } + /** Fare basis code. */ + @SerializedName("fare_basis_code") + Object fareBasisCode; - /** Departure city. */ - public Builder setCity(EmptyParam city) { - this.city = city; - return this; - } + /** Additional fees. */ + @SerializedName("fees") + Long fees; - /** Departure country. */ - public Builder setCountry(String country) { - this.country = country; - return this; - } + /** Flight number. */ + @SerializedName("flight_number") + Object flightNumber; - /** Departure country. */ - public Builder setCountry(EmptyParam country) { - this.country = country; - return this; - } + /** Stopover indicator. */ + @SerializedName("is_stop_over_indicator") + Boolean isStopOverIndicator; - /** Required. Departure date/time. */ - public Builder setDepartsAt(Long departsAt) { - this.departsAt = departsAt; - return this; - } + /** Refundable ticket indicator. */ + @SerializedName("refundable") + Boolean refundable; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData.Segment.Departure#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Required. Class of service. */ + @SerializedName("service_class") + ServiceClass serviceClass; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData.Segment.Departure#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } - } - } + /** Tax amount for segment. */ + @SerializedName("tax_amount") + Long taxAmount; - public enum ServiceClass implements ApiRequestParams.EnumParam { - @SerializedName("business") - BUSINESS("business"), + /** Ticket number. */ + @SerializedName("ticket_number") + Object ticketNumber; - @SerializedName("economy") - ECONOMY("economy"), + private Segment( + Long amount, + Arrival arrival, + Object carrierCode, + Object carrierName, + Object currency, + Departure departure, + Object exchangeTicketNumber, + Map extraParams, + Object fareBasisCode, + Long fees, + Object flightNumber, + Boolean isStopOverIndicator, + Boolean refundable, + ServiceClass serviceClass, + Long taxAmount, + Object ticketNumber) { + this.amount = amount; + this.arrival = arrival; + this.carrierCode = carrierCode; + this.carrierName = carrierName; + this.currency = currency; + this.departure = departure; + this.exchangeTicketNumber = exchangeTicketNumber; + this.extraParams = extraParams; + this.fareBasisCode = fareBasisCode; + this.fees = fees; + this.flightNumber = flightNumber; + this.isStopOverIndicator = isStopOverIndicator; + this.refundable = refundable; + this.serviceClass = serviceClass; + this.taxAmount = taxAmount; + this.ticketNumber = ticketNumber; + } - @SerializedName("first_class") - FIRST_CLASS("first_class"), + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private Arrival arrival; + + private Object carrierCode; + + private Object carrierName; + + private Object currency; + + private Departure departure; + + private Object exchangeTicketNumber; + + private Map extraParams; + + private Object fareBasisCode; + + private Long fees; + + private Object flightNumber; + + private Boolean isStopOverIndicator; + + private Boolean refundable; + + private ServiceClass serviceClass; + + private Long taxAmount; + + private Object ticketNumber; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.FlightData.Segment build() { + return new ChargeUpdateParams.PaymentDetails.FlightData.Segment( + this.amount, + this.arrival, + this.carrierCode, + this.carrierName, + this.currency, + this.departure, + this.exchangeTicketNumber, + this.extraParams, + this.fareBasisCode, + this.fees, + this.flightNumber, + this.isStopOverIndicator, + this.refundable, + this.serviceClass, + this.taxAmount, + this.ticketNumber); + } + + /** Segment fare amount. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Required. Arrival details. */ + public Builder setArrival( + ChargeUpdateParams.PaymentDetails.FlightData.Segment.Arrival arrival) { + this.arrival = arrival; + return this; + } + + /** Required. Airline carrier code. */ + public Builder setCarrierCode(String carrierCode) { + this.carrierCode = carrierCode; + return this; + } + + /** Required. Airline carrier code. */ + public Builder setCarrierCode(EmptyParam carrierCode) { + this.carrierCode = carrierCode; + return this; + } + + /** Carrier name. */ + public Builder setCarrierName(String carrierName) { + this.carrierName = carrierName; + return this; + } + + /** Carrier name. */ + public Builder setCarrierName(EmptyParam carrierName) { + this.carrierName = carrierName; + return this; + } + + /** Segment currency. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; + } + + /** Segment currency. */ + public Builder setCurrency(EmptyParam currency) { + this.currency = currency; + return this; + } + + /** Required. Departure details. */ + public Builder setDeparture( + ChargeUpdateParams.PaymentDetails.FlightData.Segment.Departure departure) { + this.departure = departure; + return this; + } + + /** Exchange ticket number. */ + public Builder setExchangeTicketNumber(String exchangeTicketNumber) { + this.exchangeTicketNumber = exchangeTicketNumber; + return this; + } + + /** Exchange ticket number. */ + public Builder setExchangeTicketNumber(EmptyParam exchangeTicketNumber) { + this.exchangeTicketNumber = exchangeTicketNumber; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Segment#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Segment#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Fare basis code. */ + public Builder setFareBasisCode(String fareBasisCode) { + this.fareBasisCode = fareBasisCode; + return this; + } + + /** Fare basis code. */ + public Builder setFareBasisCode(EmptyParam fareBasisCode) { + this.fareBasisCode = fareBasisCode; + return this; + } + + /** Additional fees. */ + public Builder setFees(Long fees) { + this.fees = fees; + return this; + } + + /** Flight number. */ + public Builder setFlightNumber(String flightNumber) { + this.flightNumber = flightNumber; + return this; + } + + /** Flight number. */ + public Builder setFlightNumber(EmptyParam flightNumber) { + this.flightNumber = flightNumber; + return this; + } + + /** Stopover indicator. */ + public Builder setIsStopOverIndicator(Boolean isStopOverIndicator) { + this.isStopOverIndicator = isStopOverIndicator; + return this; + } + + /** Refundable ticket indicator. */ + public Builder setRefundable(Boolean refundable) { + this.refundable = refundable; + return this; + } + + /** Required. Class of service. */ + public Builder setServiceClass( + ChargeUpdateParams.PaymentDetails.FlightData.Segment.ServiceClass serviceClass) { + this.serviceClass = serviceClass; + return this; + } + + /** Tax amount for segment. */ + public Builder setTaxAmount(Long taxAmount) { + this.taxAmount = taxAmount; + return this; + } + + /** Ticket number. */ + public Builder setTicketNumber(String ticketNumber) { + this.ticketNumber = ticketNumber; + return this; + } + + /** Ticket number. */ + public Builder setTicketNumber(EmptyParam ticketNumber) { + this.ticketNumber = ticketNumber; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Arrival { + /** Required. Arrival airport IATA code. */ + @SerializedName("airport") + Object airport; + + /** Arrival date/time. */ + @SerializedName("arrives_at") + Long arrivesAt; + + /** Arrival city. */ + @SerializedName("city") + Object city; + + /** Arrival country. */ + @SerializedName("country") + Object country; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Arrival( + Object airport, + Long arrivesAt, + Object city, + Object country, + Map extraParams) { + this.airport = airport; + this.arrivesAt = arrivesAt; + this.city = city; + this.country = country; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object airport; + + private Long arrivesAt; + + private Object city; + + private Object country; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.FlightData.Segment.Arrival build() { + return new ChargeUpdateParams.PaymentDetails.FlightData.Segment.Arrival( + this.airport, this.arrivesAt, this.city, this.country, this.extraParams); + } + + /** Required. Arrival airport IATA code. */ + public Builder setAirport(String airport) { + this.airport = airport; + return this; + } + + /** Required. Arrival airport IATA code. */ + public Builder setAirport(EmptyParam airport) { + this.airport = airport; + return this; + } + + /** Arrival date/time. */ + public Builder setArrivesAt(Long arrivesAt) { + this.arrivesAt = arrivesAt; + return this; + } + + /** Arrival city. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** Arrival city. */ + public Builder setCity(EmptyParam city) { + this.city = city; + return this; + } + + /** Arrival country. */ + public Builder setCountry(String country) { + this.country = country; + return this; + } + + /** Arrival country. */ + public Builder setCountry(EmptyParam country) { + this.country = country; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData.Segment.Arrival#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData.Segment.Arrival#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Departure { + /** Required. Departure airport IATA code. */ + @SerializedName("airport") + Object airport; + + /** Departure city. */ + @SerializedName("city") + Object city; + + /** Departure country. */ + @SerializedName("country") + Object country; + + /** Required. Departure date/time. */ + @SerializedName("departs_at") + Long departsAt; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Departure( + Object airport, + Object city, + Object country, + Long departsAt, + Map extraParams) { + this.airport = airport; + this.city = city; + this.country = country; + this.departsAt = departsAt; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object airport; + + private Object city; + + private Object country; + + private Long departsAt; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.FlightData.Segment.Departure build() { + return new ChargeUpdateParams.PaymentDetails.FlightData.Segment.Departure( + this.airport, this.city, this.country, this.departsAt, this.extraParams); + } + + /** Required. Departure airport IATA code. */ + public Builder setAirport(String airport) { + this.airport = airport; + return this; + } + + /** Required. Departure airport IATA code. */ + public Builder setAirport(EmptyParam airport) { + this.airport = airport; + return this; + } + + /** Departure city. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** Departure city. */ + public Builder setCity(EmptyParam city) { + this.city = city; + return this; + } + + /** Departure country. */ + public Builder setCountry(String country) { + this.country = country; + return this; + } + + /** Departure country. */ + public Builder setCountry(EmptyParam country) { + this.country = country; + return this; + } + + /** Required. Departure date/time. */ + public Builder setDepartsAt(Long departsAt) { + this.departsAt = departsAt; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData.Segment.Departure#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData.Segment.Departure#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + public enum ServiceClass implements ApiRequestParams.EnumParam { + @SerializedName("business") + BUSINESS("business"), + + @SerializedName("economy") + ECONOMY("economy"), + + @SerializedName("first_class") + FIRST_CLASS("first_class"), + + @SerializedName("premium_economy") + PREMIUM_ECONOMY("premium_economy"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ServiceClass(String value) { + this.value = value; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Total { + /** Required. Total flight amount. */ + @SerializedName("amount") + Long amount; + + /** Reason for credit. */ + @SerializedName("credit_reason") + CreditReason creditReason; + + /** Total currency. */ + @SerializedName("currency") + Object currency; + + /** Discount details. */ + @SerializedName("discounts") + Discounts discounts; + + /** Additional charges. */ + @SerializedName("extra_charges") + List extraCharges; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Tax breakdown. */ + @SerializedName("tax") + Tax tax; + + private Total( + Long amount, + CreditReason creditReason, + Object currency, + Discounts discounts, + List extraCharges, + Map extraParams, + Tax tax) { + this.amount = amount; + this.creditReason = creditReason; + this.currency = currency; + this.discounts = discounts; + this.extraCharges = extraCharges; + this.extraParams = extraParams; + this.tax = tax; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private CreditReason creditReason; + + private Object currency; + + private Discounts discounts; + + private List extraCharges; + + private Map extraParams; + + private Tax tax; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.FlightData.Total build() { + return new ChargeUpdateParams.PaymentDetails.FlightData.Total( + this.amount, + this.creditReason, + this.currency, + this.discounts, + this.extraCharges, + this.extraParams, + this.tax); + } + + /** Required. Total flight amount. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Reason for credit. */ + public Builder setCreditReason( + ChargeUpdateParams.PaymentDetails.FlightData.Total.CreditReason creditReason) { + this.creditReason = creditReason; + return this; + } + + /** Total currency. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; + } + + /** Total currency. */ + public Builder setCurrency(EmptyParam currency) { + this.currency = currency; + return this; + } + + /** Discount details. */ + public Builder setDiscounts( + ChargeUpdateParams.PaymentDetails.FlightData.Total.Discounts discounts) { + this.discounts = discounts; + return this; + } + + /** + * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData.Total#extraCharges} for the field + * documentation. + */ + public Builder addExtraCharge( + ChargeUpdateParams.PaymentDetails.FlightData.Total.ExtraCharge element) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.add(element); + return this; + } + + /** + * Add all elements to `extraCharges` list. A list is initialized for the first + * `add/addAll` call, and subsequent calls adds additional elements to the original list. + * See {@link ChargeUpdateParams.PaymentDetails.FlightData.Total#extraCharges} for the + * field documentation. + */ + public Builder addAllExtraCharge( + List elements) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.addAll(elements); + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Total#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Total#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Tax breakdown. */ + public Builder setTax(ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax tax) { + this.tax = tax; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Discounts { + /** Corporate client discount code. */ + @SerializedName("corporate_client_code") + Object corporateClientCode; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Discounts(Object corporateClientCode, Map extraParams) { + this.corporateClientCode = corporateClientCode; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object corporateClientCode; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.FlightData.Total.Discounts build() { + return new ChargeUpdateParams.PaymentDetails.FlightData.Total.Discounts( + this.corporateClientCode, this.extraParams); + } + + /** Corporate client discount code. */ + public Builder setCorporateClientCode(String corporateClientCode) { + this.corporateClientCode = corporateClientCode; + return this; + } + + /** Corporate client discount code. */ + public Builder setCorporateClientCode(EmptyParam corporateClientCode) { + this.corporateClientCode = corporateClientCode; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData.Total.Discounts#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData.Total.Discounts#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ExtraCharge { + /** Amount of additional charges. */ + @SerializedName("amount") + Long amount; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Type of additional charges. */ + @SerializedName("type") + Type type; + + private ExtraCharge(Long amount, Map extraParams, Type type) { + this.amount = amount; + this.extraParams = extraParams; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private Map extraParams; + + private Type type; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.FlightData.Total.ExtraCharge build() { + return new ChargeUpdateParams.PaymentDetails.FlightData.Total.ExtraCharge( + this.amount, this.extraParams, this.type); + } + + /** Amount of additional charges. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData.Total.ExtraCharge#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData.Total.ExtraCharge#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Type of additional charges. */ + public Builder setType( + ChargeUpdateParams.PaymentDetails.FlightData.Total.ExtraCharge.Type type) { + this.type = type; + return this; + } + } + + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("additional_fees") + ADDITIONAL_FEES("additional_fees"), + + @SerializedName("ancillary_service_charges") + ANCILLARY_SERVICE_CHARGES("ancillary_service_charges"), + + @SerializedName("exchange_fee") + EXCHANGE_FEE("exchange_fee"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Type(String value) { + this.value = value; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Tax { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Array of tax details. */ + @SerializedName("taxes") + List taxes; + + private Tax( + Map extraParams, + List taxes) { + this.extraParams = extraParams; + this.taxes = taxes; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private List taxes; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax build() { + return new ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax( + this.extraParams, this.taxes); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax#extraParams} for the field + * documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax#extraParams} for the field + * documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Add an element to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax#taxes} for the field + * documentation. + */ + public Builder addTax( + ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax.InnerTax element) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.add(element); + return this; + } + + /** + * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax#taxes} for the field + * documentation. + */ + public Builder addAllTax( + List elements) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.addAll(elements); + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class InnerTax { + /** Tax amount. */ + @SerializedName("amount") + Long amount; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Tax rate. */ + @SerializedName("rate") + Long rate; + + /** Type of tax. */ + @SerializedName("type") + Object type; + + private InnerTax(Long amount, Map extraParams, Long rate, Object type) { + this.amount = amount; + this.extraParams = extraParams; + this.rate = rate; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private Map extraParams; + + private Long rate; + + private Object type; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax.InnerTax build() { + return new ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax.InnerTax( + this.amount, this.extraParams, this.rate, this.type); + } + + /** Tax amount. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax.InnerTax#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax.InnerTax#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Tax rate. */ + public Builder setRate(Long rate) { + this.rate = rate; + return this; + } + + /** Type of tax. */ + public Builder setType(String type) { + this.type = type; + return this; + } + + /** Type of tax. */ + public Builder setType(EmptyParam type) { + this.type = type; + return this; + } + } + } + } + + public enum CreditReason implements ApiRequestParams.EnumParam { + @SerializedName("other") + OTHER("other"), + + @SerializedName("partial_ticket_refund") + PARTIAL_TICKET_REFUND("partial_ticket_refund"), + + @SerializedName("passenger_transport_ancillary_cancellation") + PASSENGER_TRANSPORT_ANCILLARY_CANCELLATION("passenger_transport_ancillary_cancellation"), + + @SerializedName("ticket_and_ancillary_cancellation") + TICKET_AND_ANCILLARY_CANCELLATION("ticket_and_ancillary_cancellation"), + + @SerializedName("ticket_cancellation") + TICKET_CANCELLATION("ticket_cancellation"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + CreditReason(String value) { + this.value = value; + } + } + } + + public enum TransactionType implements ApiRequestParams.EnumParam { + @SerializedName("exchange_ticket") + EXCHANGE_TICKET("exchange_ticket"), + + @SerializedName("miscellaneous") + MISCELLANEOUS("miscellaneous"), + + @SerializedName("refund") + REFUND("refund"), + + @SerializedName("ticket_purchase") + TICKET_PURCHASE("ticket_purchase"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + TransactionType(String value) { + this.value = value; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Lodging { + /** The lodging location's address. */ + @SerializedName("address") + Address address; + + /** The number of adults on the booking. */ + @SerializedName("adults") + Long adults; + + /** Affiliate details for this purchase. */ + @SerializedName("affiliate") + Affiliate affiliate; + + /** The booking number associated with the lodging reservation. */ + @SerializedName("booking_number") + Object bookingNumber; + + /** The lodging category. */ + @SerializedName("category") + Category category; + + /** + * Required. Lodging check-in time. Measured in seconds since the Unix epoch. + */ + @SerializedName("checkin_at") + Long checkinAt; + + /** + * Required. Lodging check-out time. Measured in seconds since the Unix + * epoch. + */ + @SerializedName("checkout_at") + Long checkoutAt; + + /** The customer service phone number of the lodging company. */ + @SerializedName("customer_service_phone_number") + Object customerServicePhoneNumber; + + /** The daily lodging room rate. */ + @SerializedName("daily_room_rate_amount") + Long dailyRoomRateAmount; + + /** Delivery details for this purchase. */ + @SerializedName("delivery") + Delivery delivery; + + /** List of additional charges being billed. */ + @SerializedName("extra_charges") + List extraCharges; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Indicates whether the lodging location is compliant with the Fire Safety Act. */ + @SerializedName("fire_safety_act_compliance") + Boolean fireSafetyActCompliance; + + /** The name of the lodging location. */ + @SerializedName("name") + Object name; + + /** + * Indicates if the customer did not keep their booking while failing to cancel the + * reservation. + */ + @SerializedName("no_show") + Boolean noShow; + + /** The number of rooms on the booking. */ + @SerializedName("number_of_rooms") + Long numberOfRooms; + + /** The details of the passengers in the travel reservation. */ + @SerializedName("passengers") + List passengers; + + /** The phone number of the lodging location. */ + @SerializedName("property_phone_number") + Object propertyPhoneNumber; + + /** The room class for this purchase. */ + @SerializedName("room_class") + Object roomClass; + + /** The number of room nights. */ + @SerializedName("room_nights") + Long roomNights; + + /** The total tax amount associating with the room reservation. */ + @SerializedName("total_room_tax_amount") + Long totalRoomTaxAmount; + + /** The total tax amount. */ + @SerializedName("total_tax_amount") + Long totalTaxAmount; + + private Lodging( + Address address, + Long adults, + Affiliate affiliate, + Object bookingNumber, + Category category, + Long checkinAt, + Long checkoutAt, + Object customerServicePhoneNumber, + Long dailyRoomRateAmount, + Delivery delivery, + List extraCharges, + Map extraParams, + Boolean fireSafetyActCompliance, + Object name, + Boolean noShow, + Long numberOfRooms, + List passengers, + Object propertyPhoneNumber, + Object roomClass, + Long roomNights, + Long totalRoomTaxAmount, + Long totalTaxAmount) { + this.address = address; + this.adults = adults; + this.affiliate = affiliate; + this.bookingNumber = bookingNumber; + this.category = category; + this.checkinAt = checkinAt; + this.checkoutAt = checkoutAt; + this.customerServicePhoneNumber = customerServicePhoneNumber; + this.dailyRoomRateAmount = dailyRoomRateAmount; + this.delivery = delivery; + this.extraCharges = extraCharges; + this.extraParams = extraParams; + this.fireSafetyActCompliance = fireSafetyActCompliance; + this.name = name; + this.noShow = noShow; + this.numberOfRooms = numberOfRooms; + this.passengers = passengers; + this.propertyPhoneNumber = propertyPhoneNumber; + this.roomClass = roomClass; + this.roomNights = roomNights; + this.totalRoomTaxAmount = totalRoomTaxAmount; + this.totalTaxAmount = totalTaxAmount; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Address address; + + private Long adults; + + private Affiliate affiliate; + + private Object bookingNumber; + + private Category category; + + private Long checkinAt; + + private Long checkoutAt; + + private Object customerServicePhoneNumber; + + private Long dailyRoomRateAmount; + + private Delivery delivery; + + private List extraCharges; + + private Map extraParams; + + private Boolean fireSafetyActCompliance; + + private Object name; + + private Boolean noShow; + + private Long numberOfRooms; + + private List passengers; + + private Object propertyPhoneNumber; + + private Object roomClass; + + private Long roomNights; + + private Long totalRoomTaxAmount; - @SerializedName("premium_economy") - PREMIUM_ECONOMY("premium_economy"); + private Long totalTaxAmount; - @Getter(onMethod_ = {@Override}) - private final String value; + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.Lodging build() { + return new ChargeUpdateParams.PaymentDetails.Lodging( + this.address, + this.adults, + this.affiliate, + this.bookingNumber, + this.category, + this.checkinAt, + this.checkoutAt, + this.customerServicePhoneNumber, + this.dailyRoomRateAmount, + this.delivery, + this.extraCharges, + this.extraParams, + this.fireSafetyActCompliance, + this.name, + this.noShow, + this.numberOfRooms, + this.passengers, + this.propertyPhoneNumber, + this.roomClass, + this.roomNights, + this.totalRoomTaxAmount, + this.totalTaxAmount); + } + + /** The lodging location's address. */ + public Builder setAddress(ChargeUpdateParams.PaymentDetails.Lodging.Address address) { + this.address = address; + return this; + } + + /** The number of adults on the booking. */ + public Builder setAdults(Long adults) { + this.adults = adults; + return this; + } + + /** Affiliate details for this purchase. */ + public Builder setAffiliate(ChargeUpdateParams.PaymentDetails.Lodging.Affiliate affiliate) { + this.affiliate = affiliate; + return this; + } + + /** The booking number associated with the lodging reservation. */ + public Builder setBookingNumber(String bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } + + /** The booking number associated with the lodging reservation. */ + public Builder setBookingNumber(EmptyParam bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } + + /** The lodging category. */ + public Builder setCategory(ChargeUpdateParams.PaymentDetails.Lodging.Category category) { + this.category = category; + return this; + } + + /** + * Required. Lodging check-in time. Measured in seconds since the Unix + * epoch. + */ + public Builder setCheckinAt(Long checkinAt) { + this.checkinAt = checkinAt; + return this; + } + + /** + * Required. Lodging check-out time. Measured in seconds since the Unix + * epoch. + */ + public Builder setCheckoutAt(Long checkoutAt) { + this.checkoutAt = checkoutAt; + return this; + } + + /** The customer service phone number of the lodging company. */ + public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; + } + + /** The customer service phone number of the lodging company. */ + public Builder setCustomerServicePhoneNumber(EmptyParam customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; + } + + /** The daily lodging room rate. */ + public Builder setDailyRoomRateAmount(Long dailyRoomRateAmount) { + this.dailyRoomRateAmount = dailyRoomRateAmount; + return this; + } + + /** Delivery details for this purchase. */ + public Builder setDelivery(ChargeUpdateParams.PaymentDetails.Lodging.Delivery delivery) { + this.delivery = delivery; + return this; + } + + /** + * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.Lodging#extraCharges} for the field documentation. + */ + public Builder addExtraCharge( + ChargeUpdateParams.PaymentDetails.Lodging.ExtraCharge element) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.add(element); + return this; + } + + /** + * Add all elements to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.Lodging#extraCharges} for the field documentation. + */ + public Builder addAllExtraCharge( + List elements) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.addAll(elements); + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging#extraParams} for the field + * documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging#extraParams} for the field + * documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Indicates whether the lodging location is compliant with the Fire Safety Act. */ + public Builder setFireSafetyActCompliance(Boolean fireSafetyActCompliance) { + this.fireSafetyActCompliance = fireSafetyActCompliance; + return this; + } + + /** The name of the lodging location. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** The name of the lodging location. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } + + /** + * Indicates if the customer did not keep their booking while failing to cancel the + * reservation. + */ + public Builder setNoShow(Boolean noShow) { + this.noShow = noShow; + return this; + } + + /** The number of rooms on the booking. */ + public Builder setNumberOfRooms(Long numberOfRooms) { + this.numberOfRooms = numberOfRooms; + return this; + } + + /** + * Add an element to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.Lodging#passengers} for the field documentation. + */ + public Builder addPassenger(ChargeUpdateParams.PaymentDetails.Lodging.Passenger element) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.add(element); + return this; + } + + /** + * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.Lodging#passengers} for the field documentation. + */ + public Builder addAllPassenger( + List elements) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.addAll(elements); + return this; + } + + /** The phone number of the lodging location. */ + public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { + this.propertyPhoneNumber = propertyPhoneNumber; + return this; + } + + /** The phone number of the lodging location. */ + public Builder setPropertyPhoneNumber(EmptyParam propertyPhoneNumber) { + this.propertyPhoneNumber = propertyPhoneNumber; + return this; + } + + /** The room class for this purchase. */ + public Builder setRoomClass(String roomClass) { + this.roomClass = roomClass; + return this; + } + + /** The room class for this purchase. */ + public Builder setRoomClass(EmptyParam roomClass) { + this.roomClass = roomClass; + return this; + } + + /** The number of room nights. */ + public Builder setRoomNights(Long roomNights) { + this.roomNights = roomNights; + return this; + } - ServiceClass(String value) { - this.value = value; - } + /** The total tax amount associating with the room reservation. */ + public Builder setTotalRoomTaxAmount(Long totalRoomTaxAmount) { + this.totalRoomTaxAmount = totalRoomTaxAmount; + return this; + } + + /** The total tax amount. */ + public Builder setTotalTaxAmount(Long totalTaxAmount) { + this.totalTaxAmount = totalTaxAmount; + return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Total { - /** Required. Total flight amount. */ - @SerializedName("amount") - Long amount; - - /** Reason for credit. */ - @SerializedName("credit_reason") - CreditReason creditReason; - - /** Total currency. */ - @SerializedName("currency") - Object currency; - - /** Discount details. */ - @SerializedName("discounts") - Discounts discounts; + public static class Address { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + Object city; - /** Additional charges. */ - @SerializedName("extra_charges") - List extraCharges; + /** + * Two-letter country code (ISO + * 3166-1 alpha-2). + */ + @SerializedName("country") + Object country; /** * Map of extra parameters for custom features not available in this client library. The @@ -7899,25 +10108,40 @@ public static class Total { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Tax breakdown. */ - @SerializedName("tax") - Tax tax; + /** Address line 1, such as the street, PO Box, or company name. */ + @SerializedName("line1") + Object line1; - private Total( - Long amount, - CreditReason creditReason, - Object currency, - Discounts discounts, - List extraCharges, + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + Object line2; + + /** ZIP or postal code. */ + @SerializedName("postal_code") + Object postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + Object state; + + private Address( + Object city, + Object country, Map extraParams, - Tax tax) { - this.amount = amount; - this.creditReason = creditReason; - this.currency = currency; - this.discounts = discounts; - this.extraCharges = extraCharges; + Object line1, + Object line2, + Object postalCode, + Object state) { + this.city = city; + this.country = country; this.extraParams = extraParams; - this.tax = tax; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; } public static Builder builder() { @@ -7925,99 +10149,188 @@ public static Builder builder() { } public static class Builder { - private Long amount; + private Object city; - private CreditReason creditReason; + private Object country; - private Object currency; + private Map extraParams; - private Discounts discounts; + private Object line1; - private List extraCharges; + private Object line2; - private Map extraParams; + private Object postalCode; - private Tax tax; + private Object state; /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.FlightData.Total build() { - return new ChargeUpdateParams.PaymentDetails.FlightData.Total( - this.amount, - this.creditReason, - this.currency, - this.discounts, - this.extraCharges, + public ChargeUpdateParams.PaymentDetails.Lodging.Address build() { + return new ChargeUpdateParams.PaymentDetails.Lodging.Address( + this.city, + this.country, this.extraParams, - this.tax); + this.line1, + this.line2, + this.postalCode, + this.state); } - /** Required. Total flight amount. */ - public Builder setAmount(Long amount) { - this.amount = amount; + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; return this; } - /** Reason for credit. */ - public Builder setCreditReason( - ChargeUpdateParams.PaymentDetails.FlightData.Total.CreditReason creditReason) { - this.creditReason = creditReason; + /** City, district, suburb, town, or village. */ + public Builder setCity(EmptyParam city) { + this.city = city; return this; } - /** Total currency. */ - public Builder setCurrency(String currency) { - this.currency = currency; + /** + * Two-letter country code (ISO + * 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; return this; } - /** Total currency. */ - public Builder setCurrency(EmptyParam currency) { - this.currency = currency; + /** + * Two-letter country code (ISO + * 3166-1 alpha-2). + */ + public Builder setCountry(EmptyParam country) { + this.country = country; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging.Address#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging.Address#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } + + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(EmptyParam line1) { + this.line1 = line1; + return this; + } + + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } + + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(EmptyParam line2) { + this.line2 = line2; + return this; + } + + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } + + /** ZIP or postal code. */ + public Builder setPostalCode(EmptyParam postalCode) { + this.postalCode = postalCode; + return this; + } + + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(EmptyParam state) { + this.state = state; return this; } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Affiliate { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Required. The name of the affiliate that originated the purchase. */ + @SerializedName("name") + Object name; + + private Affiliate(Map extraParams, Object name) { + this.extraParams = extraParams; + this.name = name; + } - /** Discount details. */ - public Builder setDiscounts( - ChargeUpdateParams.PaymentDetails.FlightData.Total.Discounts discounts) { - this.discounts = discounts; - return this; - } + public static Builder builder() { + return new Builder(); + } - /** - * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData.Total#extraCharges} for the field - * documentation. - */ - public Builder addExtraCharge( - ChargeUpdateParams.PaymentDetails.FlightData.Total.ExtraCharge element) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.add(element); - return this; - } + public static class Builder { + private Map extraParams; - /** - * Add all elements to `extraCharges` list. A list is initialized for the first - * `add/addAll` call, and subsequent calls adds additional elements to the original list. - * See {@link ChargeUpdateParams.PaymentDetails.FlightData.Total#extraCharges} for the - * field documentation. - */ - public Builder addAllExtraCharge( - List elements) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.addAll(elements); - return this; + private Object name; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.Lodging.Affiliate build() { + return new ChargeUpdateParams.PaymentDetails.Lodging.Affiliate( + this.extraParams, this.name); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Total#extraParams} for the - * field documentation. + * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging.Affiliate#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -8030,8 +10343,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.FlightData.Total#extraParams} for the - * field documentation. + * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging.Affiliate#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -8041,204 +10354,113 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Tax breakdown. */ - public Builder setTax(ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax tax) { - this.tax = tax; + /** Required. The name of the affiliate that originated the purchase. */ + public Builder setName(String name) { + this.name = name; return this; } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Discounts { - /** Corporate client discount code. */ - @SerializedName("corporate_client_code") - Object corporateClientCode; - - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; - - private Discounts(Object corporateClientCode, Map extraParams) { - this.corporateClientCode = corporateClientCode; - this.extraParams = extraParams; - } - public static Builder builder() { - return new Builder(); + /** Required. The name of the affiliate that originated the purchase. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; } + } + } - public static class Builder { - private Object corporateClientCode; - - private Map extraParams; - - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.FlightData.Total.Discounts build() { - return new ChargeUpdateParams.PaymentDetails.FlightData.Total.Discounts( - this.corporateClientCode, this.extraParams); - } - - /** Corporate client discount code. */ - public Builder setCorporateClientCode(String corporateClientCode) { - this.corporateClientCode = corporateClientCode; - return this; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Delivery { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Corporate client discount code. */ - public Builder setCorporateClientCode(EmptyParam corporateClientCode) { - this.corporateClientCode = corporateClientCode; - return this; - } + /** The delivery method for the payment. */ + @SerializedName("mode") + Mode mode; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData.Total.Discounts#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Details of the recipient. */ + @SerializedName("recipient") + Recipient recipient; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData.Total.Discounts#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } - } + private Delivery(Map extraParams, Mode mode, Recipient recipient) { + this.extraParams = extraParams; + this.mode = mode; + this.recipient = recipient; } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class ExtraCharge { - /** Amount of additional charges. */ - @SerializedName("amount") - Long amount; + public static Builder builder() { + return new Builder(); + } - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public static class Builder { + private Map extraParams; - /** Type of additional charges. */ - @SerializedName("type") - Type type; + private Mode mode; - private ExtraCharge(Long amount, Map extraParams, Type type) { - this.amount = amount; - this.extraParams = extraParams; - this.type = type; - } + private Recipient recipient; - public static Builder builder() { - return new Builder(); + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.Lodging.Delivery build() { + return new ChargeUpdateParams.PaymentDetails.Lodging.Delivery( + this.extraParams, this.mode, this.recipient); } - public static class Builder { - private Long amount; - - private Map extraParams; - - private Type type; - - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.FlightData.Total.ExtraCharge build() { - return new ChargeUpdateParams.PaymentDetails.FlightData.Total.ExtraCharge( - this.amount, this.extraParams, this.type); - } - - /** Amount of additional charges. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } - - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData.Total.ExtraCharge#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } - - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData.Total.ExtraCharge#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } - - /** Type of additional charges. */ - public Builder setType( - ChargeUpdateParams.PaymentDetails.FlightData.Total.ExtraCharge.Type type) { - this.type = type; - return this; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging.Delivery#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.put(key, value); + return this; } - public enum Type implements ApiRequestParams.EnumParam { - @SerializedName("additional_fees") - ADDITIONAL_FEES("additional_fees"), - - @SerializedName("ancillary_service_charges") - ANCILLARY_SERVICE_CHARGES("ancillary_service_charges"), - - @SerializedName("exchange_fee") - EXCHANGE_FEE("exchange_fee"); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging.Delivery#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** The delivery method for the payment. */ + public Builder setMode(ChargeUpdateParams.PaymentDetails.Lodging.Delivery.Mode mode) { + this.mode = mode; + return this; + } - Type(String value) { - this.value = value; - } + /** Details of the recipient. */ + public Builder setRecipient( + ChargeUpdateParams.PaymentDetails.Lodging.Delivery.Recipient recipient) { + this.recipient = recipient; + return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Tax { + public static class Recipient { + /** The email of the recipient the ticket is delivered to. */ + @SerializedName("email") + Object email; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -8249,15 +10471,20 @@ public static class Tax { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Array of tax details. */ - @SerializedName("taxes") - List taxes; + /** The name of the recipient the ticket is delivered to. */ + @SerializedName("name") + Object name; - private Tax( - Map extraParams, - List taxes) { + /** The phone number of the recipient the ticket is delivered to. */ + @SerializedName("phone") + Object phone; + + private Recipient( + Object email, Map extraParams, Object name, Object phone) { + this.email = email; this.extraParams = extraParams; - this.taxes = taxes; + this.name = name; + this.phone = phone; } public static Builder builder() { @@ -8265,22 +10492,38 @@ public static Builder builder() { } public static class Builder { + private Object email; + private Map extraParams; - private List taxes; + private Object name; + + private Object phone; /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax build() { - return new ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax( - this.extraParams, this.taxes); + public ChargeUpdateParams.PaymentDetails.Lodging.Delivery.Recipient build() { + return new ChargeUpdateParams.PaymentDetails.Lodging.Delivery.Recipient( + this.email, this.extraParams, this.name, this.phone); + } + + /** The email of the recipient the ticket is delivered to. */ + public Builder setEmail(String email) { + this.email = email; + return this; + } + + /** The email of the recipient the ticket is delivered to. */ + public Builder setEmail(EmptyParam email) { + this.email = email; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax#extraParams} for the field - * documentation. + * ChargeUpdateParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -8294,8 +10537,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax#extraParams} for the field - * documentation. + * ChargeUpdateParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for the + * field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -8305,187 +10548,179 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Add an element to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addTax( - ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax.InnerTax element) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.add(element); + /** The name of the recipient the ticket is delivered to. */ + public Builder setName(String name) { + this.name = name; return this; } - /** - * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addAllTax( - List elements) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.addAll(elements); + /** The name of the recipient the ticket is delivered to. */ + public Builder setName(EmptyParam name) { + this.name = name; return this; } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class InnerTax { - /** Tax amount. */ - @SerializedName("amount") - Long amount; - - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} - * value. Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; - - /** Tax rate. */ - @SerializedName("rate") - Long rate; - /** Type of tax. */ - @SerializedName("type") - Object type; - - private InnerTax(Long amount, Map extraParams, Long rate, Object type) { - this.amount = amount; - this.extraParams = extraParams; - this.rate = rate; - this.type = type; + /** The phone number of the recipient the ticket is delivered to. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; } - public static Builder builder() { - return new Builder(); + /** The phone number of the recipient the ticket is delivered to. */ + public Builder setPhone(EmptyParam phone) { + this.phone = phone; + return this; } + } + } - public static class Builder { - private Long amount; + public enum Mode implements ApiRequestParams.EnumParam { + @SerializedName("email") + EMAIL("email"), - private Map extraParams; + @SerializedName("phone") + PHONE("phone"), - private Long rate; + @SerializedName("pickup") + PICKUP("pickup"), - private Object type; + @SerializedName("post") + POST("post"); - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax.InnerTax build() { - return new ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax.InnerTax( - this.amount, this.extraParams, this.rate, this.type); - } + @Getter(onMethod_ = {@Override}) + private final String value; - /** Tax amount. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + Mode(String value) { + this.value = value; + } + } + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax.InnerTax#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Passenger { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the - * first `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeUpdateParams.PaymentDetails.FlightData.Total.Tax.InnerTax#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** + * Required. Full name of the person or entity on the lodging reservation. + */ + @SerializedName("name") + Object name; + + private Passenger(Map extraParams, Object name) { + this.extraParams = extraParams; + this.name = name; + } + + public static Builder builder() { + return new Builder(); + } - /** Tax rate. */ - public Builder setRate(Long rate) { - this.rate = rate; - return this; - } + public static class Builder { + private Map extraParams; - /** Type of tax. */ - public Builder setType(String type) { - this.type = type; - return this; - } + private Object name; - /** Type of tax. */ - public Builder setType(EmptyParam type) { - this.type = type; - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.Lodging.Passenger build() { + return new ChargeUpdateParams.PaymentDetails.Lodging.Passenger( + this.extraParams, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging.Passenger#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.put(key, value); + return this; } - } - public enum CreditReason implements ApiRequestParams.EnumParam { - @SerializedName("other") - OTHER("other"), + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging.Passenger#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - @SerializedName("partial_ticket_refund") - PARTIAL_TICKET_REFUND("partial_ticket_refund"), + /** + * Required. Full name of the person or entity on the lodging + * reservation. + */ + public Builder setName(String name) { + this.name = name; + return this; + } - @SerializedName("passenger_transport_ancillary_cancellation") - PASSENGER_TRANSPORT_ANCILLARY_CANCELLATION("passenger_transport_ancillary_cancellation"), + /** + * Required. Full name of the person or entity on the lodging + * reservation. + */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } + } + } - @SerializedName("ticket_and_ancillary_cancellation") - TICKET_AND_ANCILLARY_CANCELLATION("ticket_and_ancillary_cancellation"), + public enum Category implements ApiRequestParams.EnumParam { + @SerializedName("hotel") + HOTEL("hotel"), - @SerializedName("ticket_cancellation") - TICKET_CANCELLATION("ticket_cancellation"); + @SerializedName("vacation_rental") + VACATION_RENTAL("vacation_rental"); - @Getter(onMethod_ = {@Override}) - private final String value; + @Getter(onMethod_ = {@Override}) + private final String value; - CreditReason(String value) { - this.value = value; - } + Category(String value) { + this.value = value; } } - public enum TransactionType implements ApiRequestParams.EnumParam { - @SerializedName("exchange_ticket") - EXCHANGE_TICKET("exchange_ticket"), + public enum ExtraCharge implements ApiRequestParams.EnumParam { + @SerializedName("gift_shop") + GIFT_SHOP("gift_shop"), - @SerializedName("miscellaneous") - MISCELLANEOUS("miscellaneous"), + @SerializedName("laundry") + LAUNDRY("laundry"), - @SerializedName("refund") - REFUND("refund"), + @SerializedName("mini_bar") + MINI_BAR("mini_bar"), - @SerializedName("ticket_purchase") - TICKET_PURCHASE("ticket_purchase"); + @SerializedName("other") + OTHER("other"), + + @SerializedName("restaurant") + RESTAURANT("restaurant"), + + @SerializedName("telephone") + TELEPHONE("telephone"); @Getter(onMethod_ = {@Override}) private final String value; - TransactionType(String value) { + ExtraCharge(String value) { this.value = value; } } @@ -8493,56 +10728,31 @@ public enum TransactionType implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class Lodging { - /** The lodging location's address. */ - @SerializedName("address") - Address address; - - /** The number of adults on the booking. */ - @SerializedName("adults") - Long adults; + public static class LodgingData { + /** Accommodation details for the lodging. */ + @SerializedName("accommodation") + Accommodation accommodation; - /** Affiliate details for this purchase. */ + /** Affiliate details if applicable. */ @SerializedName("affiliate") Affiliate affiliate; - /** The booking number associated with the lodging reservation. */ + /** Booking confirmation number for the lodging. */ @SerializedName("booking_number") Object bookingNumber; - /** The lodging category. */ - @SerializedName("category") - Category category; - - /** - * Required. Lodging check-in time. Measured in seconds since the Unix epoch. - */ + /** Required. Check-in date. */ @SerializedName("checkin_at") Long checkinAt; - /** - * Required. Lodging check-out time. Measured in seconds since the Unix - * epoch. - */ + /** Required. Check-out date. */ @SerializedName("checkout_at") Long checkoutAt; - /** The customer service phone number of the lodging company. */ + /** Customer service phone number for the lodging company. */ @SerializedName("customer_service_phone_number") Object customerServicePhoneNumber; - /** The daily lodging room rate. */ - @SerializedName("daily_room_rate_amount") - Long dailyRoomRateAmount; - - /** Delivery details for this purchase. */ - @SerializedName("delivery") - Delivery delivery; - - /** List of additional charges being billed. */ - @SerializedName("extra_charges") - List extraCharges; - /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -8552,94 +10762,69 @@ public static class Lodging { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Indicates whether the lodging location is compliant with the Fire Safety Act. */ - @SerializedName("fire_safety_act_compliance") - Boolean fireSafetyActCompliance; - - /** The name of the lodging location. */ - @SerializedName("name") - Object name; - - /** - * Indicates if the customer did not keep their booking while failing to cancel the - * reservation. - */ - @SerializedName("no_show") - Boolean noShow; + /** Whether the lodging is compliant with any hotel fire safety regulations. */ + @SerializedName("fire_safety_act_compliance_indicator") + Boolean fireSafetyActComplianceIndicator; - /** The number of rooms on the booking. */ - @SerializedName("number_of_rooms") - Long numberOfRooms; + /** List of guests for the lodging. */ + @SerializedName("guests") + List guests; - /** The details of the passengers in the travel reservation. */ - @SerializedName("passengers") - List passengers; + /** Host details for the lodging. */ + @SerializedName("host") + Host host; - /** The phone number of the lodging location. */ - @SerializedName("property_phone_number") - Object propertyPhoneNumber; + /** List of insurances for the lodging. */ + @SerializedName("insurances") + List insurances; - /** The room class for this purchase. */ - @SerializedName("room_class") - Object roomClass; + /** Whether the renter is a no-show. */ + @SerializedName("no_show_indicator") + Boolean noShowIndicator; - /** The number of room nights. */ - @SerializedName("room_nights") - Long roomNights; + /** Renter ID number for the lodging. */ + @SerializedName("renter_id_number") + Object renterIdNumber; - /** The total tax amount associating with the room reservation. */ - @SerializedName("total_room_tax_amount") - Long totalRoomTaxAmount; + /** Renter name for the lodging. */ + @SerializedName("renter_name") + Object renterName; - /** The total tax amount. */ - @SerializedName("total_tax_amount") - Long totalTaxAmount; + /** Required. Total details for the lodging. */ + @SerializedName("total") + Total total; - private Lodging( - Address address, - Long adults, + private LodgingData( + Accommodation accommodation, Affiliate affiliate, Object bookingNumber, - Category category, Long checkinAt, Long checkoutAt, Object customerServicePhoneNumber, - Long dailyRoomRateAmount, - Delivery delivery, - List extraCharges, Map extraParams, - Boolean fireSafetyActCompliance, - Object name, - Boolean noShow, - Long numberOfRooms, - List passengers, - Object propertyPhoneNumber, - Object roomClass, - Long roomNights, - Long totalRoomTaxAmount, - Long totalTaxAmount) { - this.address = address; - this.adults = adults; + Boolean fireSafetyActComplianceIndicator, + List guests, + Host host, + List insurances, + Boolean noShowIndicator, + Object renterIdNumber, + Object renterName, + Total total) { + this.accommodation = accommodation; this.affiliate = affiliate; this.bookingNumber = bookingNumber; - this.category = category; this.checkinAt = checkinAt; this.checkoutAt = checkoutAt; this.customerServicePhoneNumber = customerServicePhoneNumber; - this.dailyRoomRateAmount = dailyRoomRateAmount; - this.delivery = delivery; - this.extraCharges = extraCharges; this.extraParams = extraParams; - this.fireSafetyActCompliance = fireSafetyActCompliance; - this.name = name; - this.noShow = noShow; - this.numberOfRooms = numberOfRooms; - this.passengers = passengers; - this.propertyPhoneNumber = propertyPhoneNumber; - this.roomClass = roomClass; - this.roomNights = roomNights; - this.totalRoomTaxAmount = totalRoomTaxAmount; - this.totalTaxAmount = totalTaxAmount; + this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; + this.guests = guests; + this.host = host; + this.insurances = insurances; + this.noShowIndicator = noShowIndicator; + this.renterIdNumber = renterIdNumber; + this.renterName = renterName; + this.total = total; } public static Builder builder() { @@ -8647,601 +10832,254 @@ public static Builder builder() { } public static class Builder { - private Address address; - - private Long adults; + private Accommodation accommodation; private Affiliate affiliate; private Object bookingNumber; - private Category category; - private Long checkinAt; private Long checkoutAt; private Object customerServicePhoneNumber; - private Long dailyRoomRateAmount; - - private Delivery delivery; - - private List extraCharges; - private Map extraParams; - private Boolean fireSafetyActCompliance; - - private Object name; - - private Boolean noShow; + private Boolean fireSafetyActComplianceIndicator; - private Long numberOfRooms; + private List guests; - private List passengers; + private Host host; - private Object propertyPhoneNumber; + private List insurances; - private Object roomClass; + private Boolean noShowIndicator; - private Long roomNights; + private Object renterIdNumber; - private Long totalRoomTaxAmount; + private Object renterName; - private Long totalTaxAmount; + private Total total; /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.Lodging build() { - return new ChargeUpdateParams.PaymentDetails.Lodging( - this.address, - this.adults, + public ChargeUpdateParams.PaymentDetails.LodgingData build() { + return new ChargeUpdateParams.PaymentDetails.LodgingData( + this.accommodation, this.affiliate, this.bookingNumber, - this.category, this.checkinAt, this.checkoutAt, this.customerServicePhoneNumber, - this.dailyRoomRateAmount, - this.delivery, - this.extraCharges, this.extraParams, - this.fireSafetyActCompliance, - this.name, - this.noShow, - this.numberOfRooms, - this.passengers, - this.propertyPhoneNumber, - this.roomClass, - this.roomNights, - this.totalRoomTaxAmount, - this.totalTaxAmount); - } - - /** The lodging location's address. */ - public Builder setAddress(ChargeUpdateParams.PaymentDetails.Lodging.Address address) { - this.address = address; - return this; - } - - /** The number of adults on the booking. */ - public Builder setAdults(Long adults) { - this.adults = adults; - return this; - } - - /** Affiliate details for this purchase. */ - public Builder setAffiliate(ChargeUpdateParams.PaymentDetails.Lodging.Affiliate affiliate) { - this.affiliate = affiliate; - return this; - } - - /** The booking number associated with the lodging reservation. */ - public Builder setBookingNumber(String bookingNumber) { - this.bookingNumber = bookingNumber; - return this; - } - - /** The booking number associated with the lodging reservation. */ - public Builder setBookingNumber(EmptyParam bookingNumber) { - this.bookingNumber = bookingNumber; - return this; - } - - /** The lodging category. */ - public Builder setCategory(ChargeUpdateParams.PaymentDetails.Lodging.Category category) { - this.category = category; - return this; - } - - /** - * Required. Lodging check-in time. Measured in seconds since the Unix - * epoch. - */ - public Builder setCheckinAt(Long checkinAt) { - this.checkinAt = checkinAt; - return this; - } - - /** - * Required. Lodging check-out time. Measured in seconds since the Unix - * epoch. - */ - public Builder setCheckoutAt(Long checkoutAt) { - this.checkoutAt = checkoutAt; - return this; - } - - /** The customer service phone number of the lodging company. */ - public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { - this.customerServicePhoneNumber = customerServicePhoneNumber; - return this; - } - - /** The customer service phone number of the lodging company. */ - public Builder setCustomerServicePhoneNumber(EmptyParam customerServicePhoneNumber) { - this.customerServicePhoneNumber = customerServicePhoneNumber; - return this; - } - - /** The daily lodging room rate. */ - public Builder setDailyRoomRateAmount(Long dailyRoomRateAmount) { - this.dailyRoomRateAmount = dailyRoomRateAmount; - return this; - } - - /** Delivery details for this purchase. */ - public Builder setDelivery(ChargeUpdateParams.PaymentDetails.Lodging.Delivery delivery) { - this.delivery = delivery; - return this; - } - - /** - * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.Lodging#extraCharges} for the field documentation. - */ - public Builder addExtraCharge( - ChargeUpdateParams.PaymentDetails.Lodging.ExtraCharge element) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.add(element); - return this; - } - - /** - * Add all elements to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.Lodging#extraCharges} for the field documentation. - */ - public Builder addAllExtraCharge( - List elements) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.addAll(elements); - return this; - } - - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging#extraParams} for the field - * documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } - - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging#extraParams} for the field - * documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } - - /** Indicates whether the lodging location is compliant with the Fire Safety Act. */ - public Builder setFireSafetyActCompliance(Boolean fireSafetyActCompliance) { - this.fireSafetyActCompliance = fireSafetyActCompliance; - return this; - } - - /** The name of the lodging location. */ - public Builder setName(String name) { - this.name = name; - return this; - } - - /** The name of the lodging location. */ - public Builder setName(EmptyParam name) { - this.name = name; - return this; - } - - /** - * Indicates if the customer did not keep their booking while failing to cancel the - * reservation. - */ - public Builder setNoShow(Boolean noShow) { - this.noShow = noShow; - return this; - } - - /** The number of rooms on the booking. */ - public Builder setNumberOfRooms(Long numberOfRooms) { - this.numberOfRooms = numberOfRooms; - return this; - } - - /** - * Add an element to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.Lodging#passengers} for the field documentation. - */ - public Builder addPassenger(ChargeUpdateParams.PaymentDetails.Lodging.Passenger element) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.add(element); - return this; + this.fireSafetyActComplianceIndicator, + this.guests, + this.host, + this.insurances, + this.noShowIndicator, + this.renterIdNumber, + this.renterName, + this.total); } - /** - * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.Lodging#passengers} for the field documentation. - */ - public Builder addAllPassenger( - List elements) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.addAll(elements); + /** Accommodation details for the lodging. */ + public Builder setAccommodation( + ChargeUpdateParams.PaymentDetails.LodgingData.Accommodation accommodation) { + this.accommodation = accommodation; return this; } - /** The phone number of the lodging location. */ - public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { - this.propertyPhoneNumber = propertyPhoneNumber; + /** Affiliate details if applicable. */ + public Builder setAffiliate( + ChargeUpdateParams.PaymentDetails.LodgingData.Affiliate affiliate) { + this.affiliate = affiliate; return this; } - /** The phone number of the lodging location. */ - public Builder setPropertyPhoneNumber(EmptyParam propertyPhoneNumber) { - this.propertyPhoneNumber = propertyPhoneNumber; + /** Booking confirmation number for the lodging. */ + public Builder setBookingNumber(String bookingNumber) { + this.bookingNumber = bookingNumber; return this; } - /** The room class for this purchase. */ - public Builder setRoomClass(String roomClass) { - this.roomClass = roomClass; + /** Booking confirmation number for the lodging. */ + public Builder setBookingNumber(EmptyParam bookingNumber) { + this.bookingNumber = bookingNumber; return this; } - /** The room class for this purchase. */ - public Builder setRoomClass(EmptyParam roomClass) { - this.roomClass = roomClass; + /** Required. Check-in date. */ + public Builder setCheckinAt(Long checkinAt) { + this.checkinAt = checkinAt; return this; } - /** The number of room nights. */ - public Builder setRoomNights(Long roomNights) { - this.roomNights = roomNights; + /** Required. Check-out date. */ + public Builder setCheckoutAt(Long checkoutAt) { + this.checkoutAt = checkoutAt; return this; } - /** The total tax amount associating with the room reservation. */ - public Builder setTotalRoomTaxAmount(Long totalRoomTaxAmount) { - this.totalRoomTaxAmount = totalRoomTaxAmount; + /** Customer service phone number for the lodging company. */ + public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; return this; } - /** The total tax amount. */ - public Builder setTotalTaxAmount(Long totalTaxAmount) { - this.totalTaxAmount = totalTaxAmount; + /** Customer service phone number for the lodging company. */ + public Builder setCustomerServicePhoneNumber(EmptyParam customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; return this; } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Address { - /** City, district, suburb, town, or village. */ - @SerializedName("city") - Object city; - - /** - * Two-letter country code (ISO - * 3166-1 alpha-2). - */ - @SerializedName("country") - Object country; /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData#extraParams} for the field + * documentation. */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; - - /** Address line 1, such as the street, PO Box, or company name. */ - @SerializedName("line1") - Object line1; - - /** Address line 2, such as the apartment, suite, unit, or building. */ - @SerializedName("line2") - Object line2; - - /** ZIP or postal code. */ - @SerializedName("postal_code") - Object postalCode; + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } /** - * State, county, province, or region (ISO 3166-2). + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData#extraParams} for the field + * documentation. */ - @SerializedName("state") - Object state; - - private Address( - Object city, - Object country, - Map extraParams, - Object line1, - Object line2, - Object postalCode, - Object state) { - this.city = city; - this.country = country; - this.extraParams = extraParams; - this.line1 = line1; - this.line2 = line2; - this.postalCode = postalCode; - this.state = state; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private Object city; - - private Object country; - - private Map extraParams; - - private Object line1; - - private Object line2; - - private Object postalCode; - - private Object state; - - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.Lodging.Address build() { - return new ChargeUpdateParams.PaymentDetails.Lodging.Address( - this.city, - this.country, - this.extraParams, - this.line1, - this.line2, - this.postalCode, - this.state); - } - - /** City, district, suburb, town, or village. */ - public Builder setCity(String city) { - this.city = city; - return this; - } - - /** City, district, suburb, town, or village. */ - public Builder setCity(EmptyParam city) { - this.city = city; - return this; - } - - /** - * Two-letter country code (ISO - * 3166-1 alpha-2). - */ - public Builder setCountry(String country) { - this.country = country; - return this; - } - - /** - * Two-letter country code (ISO - * 3166-1 alpha-2). - */ - public Builder setCountry(EmptyParam country) { - this.country = country; - return this; - } - - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging.Address#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } - - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging.Address#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } - - /** Address line 1, such as the street, PO Box, or company name. */ - public Builder setLine1(String line1) { - this.line1 = line1; - return this; - } - - /** Address line 1, such as the street, PO Box, or company name. */ - public Builder setLine1(EmptyParam line1) { - this.line1 = line1; - return this; - } - - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(String line2) { - this.line2 = line2; - return this; - } - - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(EmptyParam line2) { - this.line2 = line2; - return this; - } - - /** ZIP or postal code. */ - public Builder setPostalCode(String postalCode) { - this.postalCode = postalCode; - return this; - } - - /** ZIP or postal code. */ - public Builder setPostalCode(EmptyParam postalCode) { - this.postalCode = postalCode; - return this; + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.putAll(map); + return this; + } - /** - * State, county, province, or region (ISO 3166-2). - */ - public Builder setState(String state) { - this.state = state; - return this; - } + /** Whether the lodging is compliant with any hotel fire safety regulations. */ + public Builder setFireSafetyActComplianceIndicator( + Boolean fireSafetyActComplianceIndicator) { + this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; + return this; + } - /** - * State, county, province, or region (ISO 3166-2). - */ - public Builder setState(EmptyParam state) { - this.state = state; - return this; + /** + * Add an element to `guests` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData#guests} for the field documentation. + */ + public Builder addGuest(ChargeUpdateParams.PaymentDetails.LodgingData.Guest element) { + if (this.guests == null) { + this.guests = new ArrayList<>(); } + this.guests.add(element); + return this; } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Affiliate { /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. + * Add all elements to `guests` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData#guests} for the field documentation. */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; - - /** Required. The name of the affiliate that originated the purchase. */ - @SerializedName("name") - Object name; + public Builder addAllGuest( + List elements) { + if (this.guests == null) { + this.guests = new ArrayList<>(); + } + this.guests.addAll(elements); + return this; + } - private Affiliate(Map extraParams, Object name) { - this.extraParams = extraParams; - this.name = name; + /** Host details for the lodging. */ + public Builder setHost(ChargeUpdateParams.PaymentDetails.LodgingData.Host host) { + this.host = host; + return this; } - public static Builder builder() { - return new Builder(); + /** + * Add an element to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData#insurances} for the field documentation. + */ + public Builder addInsurance( + ChargeUpdateParams.PaymentDetails.LodgingData.Insurance element) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); + } + this.insurances.add(element); + return this; } - public static class Builder { - private Map extraParams; + /** + * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData#insurances} for the field documentation. + */ + public Builder addAllInsurance( + List elements) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); + } + this.insurances.addAll(elements); + return this; + } - private Object name; + /** Whether the renter is a no-show. */ + public Builder setNoShowIndicator(Boolean noShowIndicator) { + this.noShowIndicator = noShowIndicator; + return this; + } - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.Lodging.Affiliate build() { - return new ChargeUpdateParams.PaymentDetails.Lodging.Affiliate( - this.extraParams, this.name); - } + /** Renter ID number for the lodging. */ + public Builder setRenterIdNumber(String renterIdNumber) { + this.renterIdNumber = renterIdNumber; + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging.Affiliate#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Renter ID number for the lodging. */ + public Builder setRenterIdNumber(EmptyParam renterIdNumber) { + this.renterIdNumber = renterIdNumber; + return this; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging.Affiliate#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** Renter name for the lodging. */ + public Builder setRenterName(String renterName) { + this.renterName = renterName; + return this; + } - /** Required. The name of the affiliate that originated the purchase. */ - public Builder setName(String name) { - this.name = name; - return this; - } + /** Renter name for the lodging. */ + public Builder setRenterName(EmptyParam renterName) { + this.renterName = renterName; + return this; + } - /** Required. The name of the affiliate that originated the purchase. */ - public Builder setName(EmptyParam name) { - this.name = name; - return this; - } + /** Required. Total details for the lodging. */ + public Builder setTotal(ChargeUpdateParams.PaymentDetails.LodgingData.Total total) { + this.total = total; + return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Delivery { + public static class Accommodation { + /** Type of accommodation. */ + @SerializedName("accommodation_type") + AccommodationType accommodationType; + + /** Bed type. */ + @SerializedName("bed_type") + Object bedType; + + /** Daily accommodation rate in cents. */ + @SerializedName("daily_rate_amount") + Long dailyRateAmount; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -9252,18 +11090,39 @@ public static class Delivery { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** The delivery method for the payment. */ - @SerializedName("mode") - Mode mode; + /** Number of nights. */ + @SerializedName("nights") + Long nights; - /** Details of the recipient. */ - @SerializedName("recipient") - Recipient recipient; + /** Number of rooms, cabanas, apartments, and so on. */ + @SerializedName("number_of_rooms") + Long numberOfRooms; - private Delivery(Map extraParams, Mode mode, Recipient recipient) { + /** Rate type. */ + @SerializedName("rate_type") + Object rateType; + + /** Whether smoking is allowed. */ + @SerializedName("smoking_indicator") + Boolean smokingIndicator; + + private Accommodation( + AccommodationType accommodationType, + Object bedType, + Long dailyRateAmount, + Map extraParams, + Long nights, + Long numberOfRooms, + Object rateType, + Boolean smokingIndicator) { + this.accommodationType = accommodationType; + this.bedType = bedType; + this.dailyRateAmount = dailyRateAmount; this.extraParams = extraParams; - this.mode = mode; - this.recipient = recipient; + this.nights = nights; + this.numberOfRooms = numberOfRooms; + this.rateType = rateType; + this.smokingIndicator = smokingIndicator; } public static Builder builder() { @@ -9271,23 +11130,67 @@ public static Builder builder() { } public static class Builder { + private AccommodationType accommodationType; + + private Object bedType; + + private Long dailyRateAmount; + private Map extraParams; - private Mode mode; + private Long nights; + + private Long numberOfRooms; + + private Object rateType; + + private Boolean smokingIndicator; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.LodgingData.Accommodation build() { + return new ChargeUpdateParams.PaymentDetails.LodgingData.Accommodation( + this.accommodationType, + this.bedType, + this.dailyRateAmount, + this.extraParams, + this.nights, + this.numberOfRooms, + this.rateType, + this.smokingIndicator); + } + + /** Type of accommodation. */ + public Builder setAccommodationType( + ChargeUpdateParams.PaymentDetails.LodgingData.Accommodation.AccommodationType + accommodationType) { + this.accommodationType = accommodationType; + return this; + } + + /** Bed type. */ + public Builder setBedType(String bedType) { + this.bedType = bedType; + return this; + } - private Recipient recipient; + /** Bed type. */ + public Builder setBedType(EmptyParam bedType) { + this.bedType = bedType; + return this; + } - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.Lodging.Delivery build() { - return new ChargeUpdateParams.PaymentDetails.Lodging.Delivery( - this.extraParams, this.mode, this.recipient); + /** Daily accommodation rate in cents. */ + public Builder setDailyRateAmount(Long dailyRateAmount) { + this.dailyRateAmount = dailyRateAmount; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging.Delivery#extraParams} for the - * field documentation. + * map. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData.Accommodation#extraParams} for the field + * documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -9300,8 +11203,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging.Delivery#extraParams} for the - * field documentation. + * map. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData.Accommodation#extraParams} for the field + * documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -9311,165 +11215,172 @@ public Builder putAllExtraParam(Map map) { return this; } - /** The delivery method for the payment. */ - public Builder setMode(ChargeUpdateParams.PaymentDetails.Lodging.Delivery.Mode mode) { - this.mode = mode; + /** Number of nights. */ + public Builder setNights(Long nights) { + this.nights = nights; return this; } - /** Details of the recipient. */ - public Builder setRecipient( - ChargeUpdateParams.PaymentDetails.Lodging.Delivery.Recipient recipient) { - this.recipient = recipient; + /** Number of rooms, cabanas, apartments, and so on. */ + public Builder setNumberOfRooms(Long numberOfRooms) { + this.numberOfRooms = numberOfRooms; + return this; + } + + /** Rate type. */ + public Builder setRateType(String rateType) { + this.rateType = rateType; + return this; + } + + /** Rate type. */ + public Builder setRateType(EmptyParam rateType) { + this.rateType = rateType; + return this; + } + + /** Whether smoking is allowed. */ + public Builder setSmokingIndicator(Boolean smokingIndicator) { + this.smokingIndicator = smokingIndicator; return this; } } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Recipient { - /** The email of the recipient the ticket is delivered to. */ - @SerializedName("email") - Object email; + public enum AccommodationType implements ApiRequestParams.EnumParam { + @SerializedName("apartment") + APARTMENT("apartment"), - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + @SerializedName("cabana") + CABANA("cabana"), - /** The name of the recipient the ticket is delivered to. */ - @SerializedName("name") - Object name; + @SerializedName("house") + HOUSE("house"), - /** The phone number of the recipient the ticket is delivered to. */ - @SerializedName("phone") - Object phone; + @SerializedName("penthouse") + PENTHOUSE("penthouse"), - private Recipient( - Object email, Map extraParams, Object name, Object phone) { - this.email = email; - this.extraParams = extraParams; - this.name = name; - this.phone = phone; - } + @SerializedName("room") + ROOM("room"), - public static Builder builder() { - return new Builder(); - } + @SerializedName("standard") + STANDARD("standard"), - public static class Builder { - private Object email; + @SerializedName("suite") + SUITE("suite"), - private Map extraParams; + @SerializedName("villa") + VILLA("villa"); - private Object name; + @Getter(onMethod_ = {@Override}) + private final String value; - private Object phone; + AccommodationType(String value) { + this.value = value; + } + } + } - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.Lodging.Delivery.Recipient build() { - return new ChargeUpdateParams.PaymentDetails.Lodging.Delivery.Recipient( - this.email, this.extraParams, this.name, this.phone); - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Affiliate { + /** Affiliate partner code. */ + @SerializedName("code") + Object code; - /** The email of the recipient the ticket is delivered to. */ - public Builder setEmail(String email) { - this.email = email; - return this; - } + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** The email of the recipient the ticket is delivered to. */ - public Builder setEmail(EmptyParam email) { - this.email = email; - return this; - } + /** Affiliate partner name. */ + @SerializedName("name") + Object name; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeUpdateParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + private Affiliate(Object code, Map extraParams, Object name) { + this.code = code; + this.extraParams = extraParams; + this.name = name; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeUpdateParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + public static Builder builder() { + return new Builder(); + } - /** The name of the recipient the ticket is delivered to. */ - public Builder setName(String name) { - this.name = name; - return this; - } + public static class Builder { + private Object code; - /** The name of the recipient the ticket is delivered to. */ - public Builder setName(EmptyParam name) { - this.name = name; - return this; - } + private Map extraParams; - /** The phone number of the recipient the ticket is delivered to. */ - public Builder setPhone(String phone) { - this.phone = phone; - return this; - } + private Object name; - /** The phone number of the recipient the ticket is delivered to. */ - public Builder setPhone(EmptyParam phone) { - this.phone = phone; - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.LodgingData.Affiliate build() { + return new ChargeUpdateParams.PaymentDetails.LodgingData.Affiliate( + this.code, this.extraParams, this.name); } - } - public enum Mode implements ApiRequestParams.EnumParam { - @SerializedName("email") - EMAIL("email"), + /** Affiliate partner code. */ + public Builder setCode(String code) { + this.code = code; + return this; + } - @SerializedName("phone") - PHONE("phone"), + /** Affiliate partner code. */ + public Builder setCode(EmptyParam code) { + this.code = code; + return this; + } - @SerializedName("pickup") - PICKUP("pickup"), + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Affiliate#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - @SerializedName("post") - POST("post"); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Affiliate#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** Affiliate partner name. */ + public Builder setName(String name) { + this.name = name; + return this; + } - Mode(String value) { - this.value = value; + /** Affiliate partner name. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Passenger { + public static class Guest { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -9480,13 +11391,11 @@ public static class Passenger { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** - * Required. Full name of the person or entity on the lodging reservation. - */ + /** Required. Guest's full name. */ @SerializedName("name") Object name; - private Passenger(Map extraParams, Object name) { + private Guest(Map extraParams, Object name) { this.extraParams = extraParams; this.name = name; } @@ -9501,15 +11410,15 @@ public static class Builder { private Object name; /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.Lodging.Passenger build() { - return new ChargeUpdateParams.PaymentDetails.Lodging.Passenger( + public ChargeUpdateParams.PaymentDetails.LodgingData.Guest build() { + return new ChargeUpdateParams.PaymentDetails.LodgingData.Guest( this.extraParams, this.name); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging.Passenger#extraParams} for + * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Guest#extraParams} for * the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -9523,7 +11432,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.Lodging.Passenger#extraParams} for + * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Guest#extraParams} for * the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -9534,19 +11443,13 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Required. Full name of the person or entity on the lodging - * reservation. - */ + /** Required. Guest's full name. */ public Builder setName(String name) { this.name = name; return this; } - /** - * Required. Full name of the person or entity on the lodging - * reservation. - */ + /** Required. Guest's full name. */ public Builder setName(EmptyParam name) { this.name = name; return this; @@ -9554,402 +11457,459 @@ public Builder setName(EmptyParam name) { } } - public enum Category implements ApiRequestParams.EnumParam { - @SerializedName("hotel") - HOTEL("hotel"), - - @SerializedName("vacation_rental") - VACATION_RENTAL("vacation_rental"); + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Host { + /** Address of the host. */ + @SerializedName("address") + Address address; - @Getter(onMethod_ = {@Override}) - private final String value; + /** Host's country of domicile. */ + @SerializedName("country_of_domicile") + Object countryOfDomicile; - Category(String value) { - this.value = value; - } - } + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - public enum ExtraCharge implements ApiRequestParams.EnumParam { - @SerializedName("gift_shop") - GIFT_SHOP("gift_shop"), + /** Reference number for the host. */ + @SerializedName("host_reference") + Object hostReference; - @SerializedName("laundry") - LAUNDRY("laundry"), + /** Type of host. */ + @SerializedName("host_type") + HostType hostType; - @SerializedName("mini_bar") - MINI_BAR("mini_bar"), + /** Name of the lodging property or host. */ + @SerializedName("name") + Object name; - @SerializedName("other") - OTHER("other"), + /** Total number of reservations for the host. */ + @SerializedName("number_of_reservations") + Long numberOfReservations; - @SerializedName("restaurant") - RESTAURANT("restaurant"), + /** Property phone number. */ + @SerializedName("property_phone_number") + Object propertyPhoneNumber; - @SerializedName("telephone") - TELEPHONE("telephone"); + /** Host's registration date. */ + @SerializedName("registered_at") + Long registeredAt; - @Getter(onMethod_ = {@Override}) - private final String value; + private Host( + Address address, + Object countryOfDomicile, + Map extraParams, + Object hostReference, + HostType hostType, + Object name, + Long numberOfReservations, + Object propertyPhoneNumber, + Long registeredAt) { + this.address = address; + this.countryOfDomicile = countryOfDomicile; + this.extraParams = extraParams; + this.hostReference = hostReference; + this.hostType = hostType; + this.name = name; + this.numberOfReservations = numberOfReservations; + this.propertyPhoneNumber = propertyPhoneNumber; + this.registeredAt = registeredAt; + } - ExtraCharge(String value) { - this.value = value; + public static Builder builder() { + return new Builder(); } - } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class LodgingData { - /** Accommodation details for the lodging. */ - @SerializedName("accommodation") - Accommodation accommodation; + public static class Builder { + private Address address; - /** Affiliate details if applicable. */ - @SerializedName("affiliate") - Affiliate affiliate; + private Object countryOfDomicile; - /** Booking confirmation number for the lodging. */ - @SerializedName("booking_number") - Object bookingNumber; + private Map extraParams; - /** Required. Check-in date. */ - @SerializedName("checkin_at") - Long checkinAt; + private Object hostReference; - /** Required. Check-out date. */ - @SerializedName("checkout_at") - Long checkoutAt; + private HostType hostType; - /** Customer service phone number for the lodging company. */ - @SerializedName("customer_service_phone_number") - Object customerServicePhoneNumber; + private Object name; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) - * name in this param object. Effectively, this map is flattened to its parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private Long numberOfReservations; - /** Whether the lodging is compliant with any hotel fire safety regulations. */ - @SerializedName("fire_safety_act_compliance_indicator") - Boolean fireSafetyActComplianceIndicator; + private Object propertyPhoneNumber; - /** List of guests for the lodging. */ - @SerializedName("guests") - List guests; + private Long registeredAt; - /** Host details for the lodging. */ - @SerializedName("host") - Host host; + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.LodgingData.Host build() { + return new ChargeUpdateParams.PaymentDetails.LodgingData.Host( + this.address, + this.countryOfDomicile, + this.extraParams, + this.hostReference, + this.hostType, + this.name, + this.numberOfReservations, + this.propertyPhoneNumber, + this.registeredAt); + } - /** List of insurances for the lodging. */ - @SerializedName("insurances") - List insurances; + /** Address of the host. */ + public Builder setAddress( + ChargeUpdateParams.PaymentDetails.LodgingData.Host.Address address) { + this.address = address; + return this; + } + + /** Host's country of domicile. */ + public Builder setCountryOfDomicile(String countryOfDomicile) { + this.countryOfDomicile = countryOfDomicile; + return this; + } + + /** Host's country of domicile. */ + public Builder setCountryOfDomicile(EmptyParam countryOfDomicile) { + this.countryOfDomicile = countryOfDomicile; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Host#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Host#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Reference number for the host. */ + public Builder setHostReference(String hostReference) { + this.hostReference = hostReference; + return this; + } + + /** Reference number for the host. */ + public Builder setHostReference(EmptyParam hostReference) { + this.hostReference = hostReference; + return this; + } - /** Whether the renter is a no-show. */ - @SerializedName("no_show_indicator") - Boolean noShowIndicator; + /** Type of host. */ + public Builder setHostType( + ChargeUpdateParams.PaymentDetails.LodgingData.Host.HostType hostType) { + this.hostType = hostType; + return this; + } - /** Renter ID number for the lodging. */ - @SerializedName("renter_id_number") - Object renterIdNumber; + /** Name of the lodging property or host. */ + public Builder setName(String name) { + this.name = name; + return this; + } - /** Renter name for the lodging. */ - @SerializedName("renter_name") - Object renterName; + /** Name of the lodging property or host. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } - /** Required. Total details for the lodging. */ - @SerializedName("total") - Total total; + /** Total number of reservations for the host. */ + public Builder setNumberOfReservations(Long numberOfReservations) { + this.numberOfReservations = numberOfReservations; + return this; + } - private LodgingData( - Accommodation accommodation, - Affiliate affiliate, - Object bookingNumber, - Long checkinAt, - Long checkoutAt, - Object customerServicePhoneNumber, - Map extraParams, - Boolean fireSafetyActComplianceIndicator, - List guests, - Host host, - List insurances, - Boolean noShowIndicator, - Object renterIdNumber, - Object renterName, - Total total) { - this.accommodation = accommodation; - this.affiliate = affiliate; - this.bookingNumber = bookingNumber; - this.checkinAt = checkinAt; - this.checkoutAt = checkoutAt; - this.customerServicePhoneNumber = customerServicePhoneNumber; - this.extraParams = extraParams; - this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; - this.guests = guests; - this.host = host; - this.insurances = insurances; - this.noShowIndicator = noShowIndicator; - this.renterIdNumber = renterIdNumber; - this.renterName = renterName; - this.total = total; - } + /** Property phone number. */ + public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { + this.propertyPhoneNumber = propertyPhoneNumber; + return this; + } - public static Builder builder() { - return new Builder(); - } + /** Property phone number. */ + public Builder setPropertyPhoneNumber(EmptyParam propertyPhoneNumber) { + this.propertyPhoneNumber = propertyPhoneNumber; + return this; + } - public static class Builder { - private Accommodation accommodation; + /** Host's registration date. */ + public Builder setRegisteredAt(Long registeredAt) { + this.registeredAt = registeredAt; + return this; + } + } - private Affiliate affiliate; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Address { + /** Required. City, district, suburb, town, or village. */ + @SerializedName("city") + Object city; - private Object bookingNumber; + /** + * Required. Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + Object country; - private Long checkinAt; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private Long checkoutAt; + /** + * Required. Address line 1, such as the street, PO Box, or company name. + */ + @SerializedName("line1") + Object line1; - private Object customerServicePhoneNumber; + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + Object line2; - private Map extraParams; + /** Required. ZIP or postal code. */ + @SerializedName("postal_code") + Object postalCode; - private Boolean fireSafetyActComplianceIndicator; + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + Object state; - private List guests; + private Address( + Object city, + Object country, + Map extraParams, + Object line1, + Object line2, + Object postalCode, + Object state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } - private Host host; + public static Builder builder() { + return new Builder(); + } - private List insurances; + public static class Builder { + private Object city; - private Boolean noShowIndicator; + private Object country; - private Object renterIdNumber; + private Map extraParams; - private Object renterName; + private Object line1; - private Total total; + private Object line2; - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.LodgingData build() { - return new ChargeUpdateParams.PaymentDetails.LodgingData( - this.accommodation, - this.affiliate, - this.bookingNumber, - this.checkinAt, - this.checkoutAt, - this.customerServicePhoneNumber, - this.extraParams, - this.fireSafetyActComplianceIndicator, - this.guests, - this.host, - this.insurances, - this.noShowIndicator, - this.renterIdNumber, - this.renterName, - this.total); - } + private Object postalCode; - /** Accommodation details for the lodging. */ - public Builder setAccommodation( - ChargeUpdateParams.PaymentDetails.LodgingData.Accommodation accommodation) { - this.accommodation = accommodation; - return this; - } + private Object state; - /** Affiliate details if applicable. */ - public Builder setAffiliate( - ChargeUpdateParams.PaymentDetails.LodgingData.Affiliate affiliate) { - this.affiliate = affiliate; - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.LodgingData.Host.Address build() { + return new ChargeUpdateParams.PaymentDetails.LodgingData.Host.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } - /** Booking confirmation number for the lodging. */ - public Builder setBookingNumber(String bookingNumber) { - this.bookingNumber = bookingNumber; - return this; - } + /** Required. City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } - /** Booking confirmation number for the lodging. */ - public Builder setBookingNumber(EmptyParam bookingNumber) { - this.bookingNumber = bookingNumber; - return this; - } + /** Required. City, district, suburb, town, or village. */ + public Builder setCity(EmptyParam city) { + this.city = city; + return this; + } - /** Required. Check-in date. */ - public Builder setCheckinAt(Long checkinAt) { - this.checkinAt = checkinAt; - return this; - } + /** + * Required. Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } - /** Required. Check-out date. */ - public Builder setCheckoutAt(Long checkoutAt) { - this.checkoutAt = checkoutAt; - return this; - } + /** + * Required. Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(EmptyParam country) { + this.country = country; + return this; + } - /** Customer service phone number for the lodging company. */ - public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { - this.customerServicePhoneNumber = customerServicePhoneNumber; - return this; - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData.Host.Address#extraParams} for the field + * documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** Customer service phone number for the lodging company. */ - public Builder setCustomerServicePhoneNumber(EmptyParam customerServicePhoneNumber) { - this.customerServicePhoneNumber = customerServicePhoneNumber; - return this; - } + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData.Host.Address#extraParams} for the field + * documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData#extraParams} for the field - * documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** + * Required. Address line 1, such as the street, PO Box, or company + * name. + */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData#extraParams} for the field - * documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** + * Required. Address line 1, such as the street, PO Box, or company + * name. + */ + public Builder setLine1(EmptyParam line1) { + this.line1 = line1; + return this; + } - /** Whether the lodging is compliant with any hotel fire safety regulations. */ - public Builder setFireSafetyActComplianceIndicator( - Boolean fireSafetyActComplianceIndicator) { - this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; - return this; - } + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } - /** - * Add an element to `guests` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData#guests} for the field documentation. - */ - public Builder addGuest(ChargeUpdateParams.PaymentDetails.LodgingData.Guest element) { - if (this.guests == null) { - this.guests = new ArrayList<>(); - } - this.guests.add(element); - return this; - } + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(EmptyParam line2) { + this.line2 = line2; + return this; + } - /** - * Add all elements to `guests` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData#guests} for the field documentation. - */ - public Builder addAllGuest( - List elements) { - if (this.guests == null) { - this.guests = new ArrayList<>(); - } - this.guests.addAll(elements); - return this; - } + /** Required. ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - /** Host details for the lodging. */ - public Builder setHost(ChargeUpdateParams.PaymentDetails.LodgingData.Host host) { - this.host = host; - return this; - } + /** Required. ZIP or postal code. */ + public Builder setPostalCode(EmptyParam postalCode) { + this.postalCode = postalCode; + return this; + } - /** - * Add an element to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData#insurances} for the field documentation. - */ - public Builder addInsurance( - ChargeUpdateParams.PaymentDetails.LodgingData.Insurance element) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); - } - this.insurances.add(element); - return this; - } + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } - /** - * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData#insurances} for the field documentation. - */ - public Builder addAllInsurance( - List elements) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(EmptyParam state) { + this.state = state; + return this; + } } - this.insurances.addAll(elements); - return this; } - /** Whether the renter is a no-show. */ - public Builder setNoShowIndicator(Boolean noShowIndicator) { - this.noShowIndicator = noShowIndicator; - return this; - } + public enum HostType implements ApiRequestParams.EnumParam { + @SerializedName("hostel") + HOSTEL("hostel"), - /** Renter ID number for the lodging. */ - public Builder setRenterIdNumber(String renterIdNumber) { - this.renterIdNumber = renterIdNumber; - return this; - } + @SerializedName("hotel") + HOTEL("hotel"), - /** Renter ID number for the lodging. */ - public Builder setRenterIdNumber(EmptyParam renterIdNumber) { - this.renterIdNumber = renterIdNumber; - return this; - } + @SerializedName("owner") + OWNER("owner"), - /** Renter name for the lodging. */ - public Builder setRenterName(String renterName) { - this.renterName = renterName; - return this; - } + @SerializedName("rental_agency") + RENTAL_AGENCY("rental_agency"); - /** Renter name for the lodging. */ - public Builder setRenterName(EmptyParam renterName) { - this.renterName = renterName; - return this; - } + @Getter(onMethod_ = {@Override}) + private final String value; - /** Required. Total details for the lodging. */ - public Builder setTotal(ChargeUpdateParams.PaymentDetails.LodgingData.Total total) { - this.total = total; - return this; + HostType(String value) { + this.value = value; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Accommodation { - /** Type of accommodation. */ - @SerializedName("accommodation_type") - AccommodationType accommodationType; - - /** Bed type. */ - @SerializedName("bed_type") - Object bedType; + public static class Insurance { + /** Required. Price of the insurance coverage in cents. */ + @SerializedName("amount") + Long amount; - /** Daily accommodation rate in cents. */ - @SerializedName("daily_rate_amount") - Long dailyRateAmount; + /** Currency of the insurance amount. */ + @SerializedName("currency") + Object currency; /** * Map of extra parameters for custom features not available in this client library. The @@ -9961,39 +11921,25 @@ public static class Accommodation { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Number of nights. */ - @SerializedName("nights") - Long nights; - - /** Number of rooms, cabanas, apartments, and so on. */ - @SerializedName("number_of_rooms") - Long numberOfRooms; - - /** Rate type. */ - @SerializedName("rate_type") - Object rateType; + /** Name of the insurance company. */ + @SerializedName("insurance_company_name") + Object insuranceCompanyName; - /** Whether smoking is allowed. */ - @SerializedName("smoking_indicator") - Boolean smokingIndicator; + /** Required. Type of insurance coverage. */ + @SerializedName("insurance_type") + InsuranceType insuranceType; - private Accommodation( - AccommodationType accommodationType, - Object bedType, - Long dailyRateAmount, + private Insurance( + Long amount, + Object currency, Map extraParams, - Long nights, - Long numberOfRooms, - Object rateType, - Boolean smokingIndicator) { - this.accommodationType = accommodationType; - this.bedType = bedType; - this.dailyRateAmount = dailyRateAmount; + Object insuranceCompanyName, + InsuranceType insuranceType) { + this.amount = amount; + this.currency = currency; this.extraParams = extraParams; - this.nights = nights; - this.numberOfRooms = numberOfRooms; - this.rateType = rateType; - this.smokingIndicator = smokingIndicator; + this.insuranceCompanyName = insuranceCompanyName; + this.insuranceType = insuranceType; } public static Builder builder() { @@ -10001,67 +11947,49 @@ public static Builder builder() { } public static class Builder { - private AccommodationType accommodationType; - - private Object bedType; + private Long amount; - private Long dailyRateAmount; + private Object currency; private Map extraParams; - private Long nights; - - private Long numberOfRooms; - - private Object rateType; + private Object insuranceCompanyName; - private Boolean smokingIndicator; + private InsuranceType insuranceType; /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.LodgingData.Accommodation build() { - return new ChargeUpdateParams.PaymentDetails.LodgingData.Accommodation( - this.accommodationType, - this.bedType, - this.dailyRateAmount, + public ChargeUpdateParams.PaymentDetails.LodgingData.Insurance build() { + return new ChargeUpdateParams.PaymentDetails.LodgingData.Insurance( + this.amount, + this.currency, this.extraParams, - this.nights, - this.numberOfRooms, - this.rateType, - this.smokingIndicator); - } - - /** Type of accommodation. */ - public Builder setAccommodationType( - ChargeUpdateParams.PaymentDetails.LodgingData.Accommodation.AccommodationType - accommodationType) { - this.accommodationType = accommodationType; - return this; + this.insuranceCompanyName, + this.insuranceType); } - /** Bed type. */ - public Builder setBedType(String bedType) { - this.bedType = bedType; + /** Required. Price of the insurance coverage in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; return this; } - /** Bed type. */ - public Builder setBedType(EmptyParam bedType) { - this.bedType = bedType; + /** Currency of the insurance amount. */ + public Builder setCurrency(String currency) { + this.currency = currency; return this; } - /** Daily accommodation rate in cents. */ - public Builder setDailyRateAmount(Long dailyRateAmount) { - this.dailyRateAmount = dailyRateAmount; + /** Currency of the insurance amount. */ + public Builder setCurrency(EmptyParam currency) { + this.currency = currency; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData.Accommodation#extraParams} for the field - * documentation. + * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Insurance#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -10074,9 +12002,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData.Accommodation#extraParams} for the field - * documentation. + * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Insurance#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -10086,66 +12013,43 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Number of nights. */ - public Builder setNights(Long nights) { - this.nights = nights; - return this; - } - - /** Number of rooms, cabanas, apartments, and so on. */ - public Builder setNumberOfRooms(Long numberOfRooms) { - this.numberOfRooms = numberOfRooms; - return this; - } - - /** Rate type. */ - public Builder setRateType(String rateType) { - this.rateType = rateType; + /** Name of the insurance company. */ + public Builder setInsuranceCompanyName(String insuranceCompanyName) { + this.insuranceCompanyName = insuranceCompanyName; return this; } - /** Rate type. */ - public Builder setRateType(EmptyParam rateType) { - this.rateType = rateType; + /** Name of the insurance company. */ + public Builder setInsuranceCompanyName(EmptyParam insuranceCompanyName) { + this.insuranceCompanyName = insuranceCompanyName; return this; } - /** Whether smoking is allowed. */ - public Builder setSmokingIndicator(Boolean smokingIndicator) { - this.smokingIndicator = smokingIndicator; + /** Required. Type of insurance coverage. */ + public Builder setInsuranceType( + ChargeUpdateParams.PaymentDetails.LodgingData.Insurance.InsuranceType insuranceType) { + this.insuranceType = insuranceType; return this; } } - public enum AccommodationType implements ApiRequestParams.EnumParam { - @SerializedName("apartment") - APARTMENT("apartment"), - - @SerializedName("cabana") - CABANA("cabana"), - - @SerializedName("house") - HOUSE("house"), - - @SerializedName("penthouse") - PENTHOUSE("penthouse"), - - @SerializedName("room") - ROOM("room"), + public enum InsuranceType implements ApiRequestParams.EnumParam { + @SerializedName("bankruptcy") + BANKRUPTCY("bankruptcy"), - @SerializedName("standard") - STANDARD("standard"), + @SerializedName("cancelation") + CANCELATION("cancelation"), - @SerializedName("suite") - SUITE("suite"), + @SerializedName("emergency") + EMERGENCY("emergency"), - @SerializedName("villa") - VILLA("villa"); + @SerializedName("medical") + MEDICAL("medical"); @Getter(onMethod_ = {@Override}) private final String value; - AccommodationType(String value) { + InsuranceType(String value) { this.value = value; } } @@ -10153,10 +12057,26 @@ public enum AccommodationType implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class Affiliate { - /** Affiliate partner code. */ - @SerializedName("code") - Object code; + public static class Total { + /** Required. Total price of the lodging reservation in cents. */ + @SerializedName("amount") + Long amount; + + /** Cash advances in cents. */ + @SerializedName("cash_advances") + Long cashAdvances; + + /** Currency of the total amount. */ + @SerializedName("currency") + Object currency; + + /** Discount details for the lodging. */ + @SerializedName("discounts") + Discounts discounts; + + /** Additional charges for the lodging. */ + @SerializedName("extra_charges") + List extraCharges; /** * Map of extra parameters for custom features not available in this client library. The @@ -10168,14 +12088,31 @@ public static class Affiliate { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Affiliate partner name. */ - @SerializedName("name") - Object name; + /** Prepaid amount in cents. */ + @SerializedName("prepaid_amount") + Long prepaidAmount; - private Affiliate(Object code, Map extraParams, Object name) { - this.code = code; + /** Tax breakdown for the lodging reservation. */ + @SerializedName("tax") + Tax tax; + + private Total( + Long amount, + Long cashAdvances, + Object currency, + Discounts discounts, + List extraCharges, + Map extraParams, + Long prepaidAmount, + Tax tax) { + this.amount = amount; + this.cashAdvances = cashAdvances; + this.currency = currency; + this.discounts = discounts; + this.extraCharges = extraCharges; this.extraParams = extraParams; - this.name = name; + this.prepaidAmount = prepaidAmount; + this.tax = tax; } public static Builder builder() { @@ -10183,113 +12120,101 @@ public static Builder builder() { } public static class Builder { - private Object code; + private Long amount; + + private Long cashAdvances; + + private Object currency; + + private Discounts discounts; + + private List + extraCharges; private Map extraParams; - private Object name; + private Long prepaidAmount; + + private Tax tax; /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.LodgingData.Affiliate build() { - return new ChargeUpdateParams.PaymentDetails.LodgingData.Affiliate( - this.code, this.extraParams, this.name); + public ChargeUpdateParams.PaymentDetails.LodgingData.Total build() { + return new ChargeUpdateParams.PaymentDetails.LodgingData.Total( + this.amount, + this.cashAdvances, + this.currency, + this.discounts, + this.extraCharges, + this.extraParams, + this.prepaidAmount, + this.tax); } - /** Affiliate partner code. */ - public Builder setCode(String code) { - this.code = code; + /** Required. Total price of the lodging reservation in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Cash advances in cents. */ + public Builder setCashAdvances(Long cashAdvances) { + this.cashAdvances = cashAdvances; + return this; + } + + /** Currency of the total amount. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; + } + + /** Currency of the total amount. */ + public Builder setCurrency(EmptyParam currency) { + this.currency = currency; return this; } - /** Affiliate partner code. */ - public Builder setCode(EmptyParam code) { - this.code = code; + /** Discount details for the lodging. */ + public Builder setDiscounts( + ChargeUpdateParams.PaymentDetails.LodgingData.Total.Discounts discounts) { + this.discounts = discounts; return this; } /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Affiliate#extraParams} - * for the field documentation. + * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData.Total#extraCharges} for the field + * documentation. */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + public Builder addExtraCharge( + ChargeUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge element) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); } - this.extraParams.put(key, value); + this.extraCharges.add(element); return this; } /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Affiliate#extraParams} - * for the field documentation. + * Add all elements to `extraCharges` list. A list is initialized for the first + * `add/addAll` call, and subsequent calls adds additional elements to the original list. + * See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Total#extraCharges} for the + * field documentation. */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + public Builder addAllExtraCharge( + List elements) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); } - this.extraParams.putAll(map); - return this; - } - - /** Affiliate partner name. */ - public Builder setName(String name) { - this.name = name; - return this; - } - - /** Affiliate partner name. */ - public Builder setName(EmptyParam name) { - this.name = name; + this.extraCharges.addAll(elements); return this; } - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Guest { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; - - /** Required. Guest's full name. */ - @SerializedName("name") - Object name; - - private Guest(Map extraParams, Object name) { - this.extraParams = extraParams; - this.name = name; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private Map extraParams; - - private Object name; - - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.LodgingData.Guest build() { - return new ChargeUpdateParams.PaymentDetails.LodgingData.Guest( - this.extraParams, this.name); - } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Guest#extraParams} for + * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Total#extraParams} for * the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -10303,7 +12228,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Guest#extraParams} for + * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Total#extraParams} for * the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -10314,240 +12239,239 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Required. Guest's full name. */ - public Builder setName(String name) { - this.name = name; + /** Prepaid amount in cents. */ + public Builder setPrepaidAmount(Long prepaidAmount) { + this.prepaidAmount = prepaidAmount; return this; } - /** Required. Guest's full name. */ - public Builder setName(EmptyParam name) { - this.name = name; + /** Tax breakdown for the lodging reservation. */ + public Builder setTax(ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax tax) { + this.tax = tax; return this; } } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Host { - /** Address of the host. */ - @SerializedName("address") - Address address; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Discounts { + /** Corporate client discount code. */ + @SerializedName("corporate_client_code") + Object corporateClientCode; - /** Host's country of domicile. */ - @SerializedName("country_of_domicile") - Object countryOfDomicile; + /** Coupon code. */ + @SerializedName("coupon") + Object coupon; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Reference number for the host. */ - @SerializedName("host_reference") - Object hostReference; + private Discounts( + Object corporateClientCode, Object coupon, Map extraParams) { + this.corporateClientCode = corporateClientCode; + this.coupon = coupon; + this.extraParams = extraParams; + } - /** Type of host. */ - @SerializedName("host_type") - HostType hostType; + public static Builder builder() { + return new Builder(); + } - /** Name of the lodging property or host. */ - @SerializedName("name") - Object name; + public static class Builder { + private Object corporateClientCode; - /** Total number of reservations for the host. */ - @SerializedName("number_of_reservations") - Long numberOfReservations; + private Object coupon; - /** Property phone number. */ - @SerializedName("property_phone_number") - Object propertyPhoneNumber; + private Map extraParams; - /** Host's registration date. */ - @SerializedName("registered_at") - Long registeredAt; + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.LodgingData.Total.Discounts build() { + return new ChargeUpdateParams.PaymentDetails.LodgingData.Total.Discounts( + this.corporateClientCode, this.coupon, this.extraParams); + } - private Host( - Address address, - Object countryOfDomicile, - Map extraParams, - Object hostReference, - HostType hostType, - Object name, - Long numberOfReservations, - Object propertyPhoneNumber, - Long registeredAt) { - this.address = address; - this.countryOfDomicile = countryOfDomicile; - this.extraParams = extraParams; - this.hostReference = hostReference; - this.hostType = hostType; - this.name = name; - this.numberOfReservations = numberOfReservations; - this.propertyPhoneNumber = propertyPhoneNumber; - this.registeredAt = registeredAt; - } + /** Corporate client discount code. */ + public Builder setCorporateClientCode(String corporateClientCode) { + this.corporateClientCode = corporateClientCode; + return this; + } - public static Builder builder() { - return new Builder(); + /** Corporate client discount code. */ + public Builder setCorporateClientCode(EmptyParam corporateClientCode) { + this.corporateClientCode = corporateClientCode; + return this; + } + + /** Coupon code. */ + public Builder setCoupon(String coupon) { + this.coupon = coupon; + return this; + } + + /** Coupon code. */ + public Builder setCoupon(EmptyParam coupon) { + this.coupon = coupon; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } } - public static class Builder { - private Address address; - - private Object countryOfDomicile; - - private Map extraParams; - - private Object hostReference; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ExtraCharge { + /** Amount of the extra charge in cents. */ + @SerializedName("amount") + Long amount; - private HostType hostType; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private Object name; + /** Type of extra charge. */ + @SerializedName("type") + Type type; - private Long numberOfReservations; + private ExtraCharge(Long amount, Map extraParams, Type type) { + this.amount = amount; + this.extraParams = extraParams; + this.type = type; + } - private Object propertyPhoneNumber; + public static Builder builder() { + return new Builder(); + } - private Long registeredAt; + public static class Builder { + private Long amount; - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.LodgingData.Host build() { - return new ChargeUpdateParams.PaymentDetails.LodgingData.Host( - this.address, - this.countryOfDomicile, - this.extraParams, - this.hostReference, - this.hostType, - this.name, - this.numberOfReservations, - this.propertyPhoneNumber, - this.registeredAt); - } + private Map extraParams; - /** Address of the host. */ - public Builder setAddress( - ChargeUpdateParams.PaymentDetails.LodgingData.Host.Address address) { - this.address = address; - return this; - } + private Type type; - /** Host's country of domicile. */ - public Builder setCountryOfDomicile(String countryOfDomicile) { - this.countryOfDomicile = countryOfDomicile; - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge build() { + return new ChargeUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge( + this.amount, this.extraParams, this.type); + } - /** Host's country of domicile. */ - public Builder setCountryOfDomicile(EmptyParam countryOfDomicile) { - this.countryOfDomicile = countryOfDomicile; - return this; - } + /** Amount of the extra charge in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Host#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; } - this.extraParams.put(key, value); - return this; - } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Host#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; } - this.extraParams.putAll(map); - return this; - } - /** Reference number for the host. */ - public Builder setHostReference(String hostReference) { - this.hostReference = hostReference; - return this; + /** Type of extra charge. */ + public Builder setType( + ChargeUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge.Type type) { + this.type = type; + return this; + } } - /** Reference number for the host. */ - public Builder setHostReference(EmptyParam hostReference) { - this.hostReference = hostReference; - return this; - } + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("gift_shop") + GIFT_SHOP("gift_shop"), - /** Type of host. */ - public Builder setHostType( - ChargeUpdateParams.PaymentDetails.LodgingData.Host.HostType hostType) { - this.hostType = hostType; - return this; - } + @SerializedName("laundry") + LAUNDRY("laundry"), - /** Name of the lodging property or host. */ - public Builder setName(String name) { - this.name = name; - return this; - } + @SerializedName("mini_bar") + MINI_BAR("mini_bar"), - /** Name of the lodging property or host. */ - public Builder setName(EmptyParam name) { - this.name = name; - return this; - } + @SerializedName("other") + OTHER("other"), - /** Total number of reservations for the host. */ - public Builder setNumberOfReservations(Long numberOfReservations) { - this.numberOfReservations = numberOfReservations; - return this; - } + @SerializedName("phone") + PHONE("phone"), - /** Property phone number. */ - public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { - this.propertyPhoneNumber = propertyPhoneNumber; - return this; - } + @SerializedName("restaurant") + RESTAURANT("restaurant"); - /** Property phone number. */ - public Builder setPropertyPhoneNumber(EmptyParam propertyPhoneNumber) { - this.propertyPhoneNumber = propertyPhoneNumber; - return this; - } + @Getter(onMethod_ = {@Override}) + private final String value; - /** Host's registration date. */ - public Builder setRegisteredAt(Long registeredAt) { - this.registeredAt = registeredAt; - return this; + Type(String value) { + this.value = value; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Address { - /** Required. City, district, suburb, town, or village. */ - @SerializedName("city") - Object city; - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - @SerializedName("country") - Object country; - + public static class Tax { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -10558,42 +12482,21 @@ public static class Address { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** - * Required. Address line 1, such as the street, PO Box, or company name. - */ - @SerializedName("line1") - Object line1; - - /** Address line 2, such as the apartment, suite, unit, or building. */ - @SerializedName("line2") - Object line2; - - /** Required. ZIP or postal code. */ - @SerializedName("postal_code") - Object postalCode; + /** Indicates whether the transaction is tax exempt. */ + @SerializedName("tax_exempt_indicator") + Boolean taxExemptIndicator; - /** - * State, county, province, or region (ISO 3166-2). - */ - @SerializedName("state") - Object state; + /** Tax details. */ + @SerializedName("taxes") + List taxes; - private Address( - Object city, - Object country, + private Tax( Map extraParams, - Object line1, - Object line2, - Object postalCode, - Object state) { - this.city = city; - this.country = country; + Boolean taxExemptIndicator, + List taxes) { this.extraParams = extraParams; - this.line1 = line1; - this.line2 = line2; - this.postalCode = postalCode; - this.state = state; + this.taxExemptIndicator = taxExemptIndicator; + this.taxes = taxes; } public static Builder builder() { @@ -10601,67 +12504,23 @@ public static Builder builder() { } public static class Builder { - private Object city; - - private Object country; - private Map extraParams; - private Object line1; - - private Object line2; - - private Object postalCode; + private Boolean taxExemptIndicator; - private Object state; + private List taxes; /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.LodgingData.Host.Address build() { - return new ChargeUpdateParams.PaymentDetails.LodgingData.Host.Address( - this.city, - this.country, - this.extraParams, - this.line1, - this.line2, - this.postalCode, - this.state); - } - - /** Required. City, district, suburb, town, or village. */ - public Builder setCity(String city) { - this.city = city; - return this; - } - - /** Required. City, district, suburb, town, or village. */ - public Builder setCity(EmptyParam city) { - this.city = city; - return this; - } - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - public Builder setCountry(String country) { - this.country = country; - return this; - } - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - public Builder setCountry(EmptyParam country) { - this.country = country; - return this; + public ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax build() { + return new ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax( + this.extraParams, this.taxExemptIndicator, this.taxes); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData.Host.Address#extraParams} for the field + * ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the field * documentation. */ public Builder putExtraParam(String key, Object value) { @@ -10676,7 +12535,7 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData.Host.Address#extraParams} for the field + * ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the field * documentation. */ public Builder putAllExtraParam(Map map) { @@ -10687,267 +12546,264 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Required. Address line 1, such as the street, PO Box, or company - * name. - */ - public Builder setLine1(String line1) { - this.line1 = line1; + /** Indicates whether the transaction is tax exempt. */ + public Builder setTaxExemptIndicator(Boolean taxExemptIndicator) { + this.taxExemptIndicator = taxExemptIndicator; return this; } /** - * Required. Address line 1, such as the street, PO Box, or company - * name. + * Add an element to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field + * documentation. */ - public Builder setLine1(EmptyParam line1) { - this.line1 = line1; - return this; - } - - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(String line2) { - this.line2 = line2; - return this; - } - - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(EmptyParam line2) { - this.line2 = line2; - return this; - } - - /** Required. ZIP or postal code. */ - public Builder setPostalCode(String postalCode) { - this.postalCode = postalCode; - return this; - } - - /** Required. ZIP or postal code. */ - public Builder setPostalCode(EmptyParam postalCode) { - this.postalCode = postalCode; + public Builder addTax( + ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax element) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.add(element); return this; } /** - * State, county, province, or region (ISO 3166-2). + * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field + * documentation. */ - public Builder setState(String state) { - this.state = state; + public Builder addAllTax( + List elements) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.addAll(elements); return this; } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class InnerTax { + /** Tax amount in cents. */ + @SerializedName("amount") + Long amount; /** - * State, county, province, or region (ISO 3166-2). + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. */ - public Builder setState(EmptyParam state) { - this.state = state; - return this; - } - } - } + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - public enum HostType implements ApiRequestParams.EnumParam { - @SerializedName("hostel") - HOSTEL("hostel"), + /** Tax rate. */ + @SerializedName("rate") + Long rate; - @SerializedName("hotel") - HOTEL("hotel"), + /** Type of tax applied. */ + @SerializedName("type") + Object type; - @SerializedName("owner") - OWNER("owner"), + private InnerTax(Long amount, Map extraParams, Long rate, Object type) { + this.amount = amount; + this.extraParams = extraParams; + this.rate = rate; + this.type = type; + } - @SerializedName("rental_agency") - RENTAL_AGENCY("rental_agency"); + public static Builder builder() { + return new Builder(); + } - @Getter(onMethod_ = {@Override}) - private final String value; + public static class Builder { + private Long amount; - HostType(String value) { - this.value = value; - } - } - } + private Map extraParams; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Insurance { - /** Required. Price of the insurance coverage in cents. */ - @SerializedName("amount") - Long amount; + private Long rate; - /** Currency of the insurance amount. */ - @SerializedName("currency") - Object currency; + private Object type; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax build() { + return new ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax( + this.amount, this.extraParams, this.rate, this.type); + } - /** Name of the insurance company. */ - @SerializedName("insurance_company_name") - Object insuranceCompanyName; + /** Tax amount in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } - /** Required. Type of insurance coverage. */ - @SerializedName("insurance_type") - InsuranceType insuranceType; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - private Insurance( - Long amount, - Object currency, - Map extraParams, - Object insuranceCompanyName, - InsuranceType insuranceType) { - this.amount = amount; - this.currency = currency; - this.extraParams = extraParams; - this.insuranceCompanyName = insuranceCompanyName; - this.insuranceType = insuranceType; - } + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Tax rate. */ + public Builder setRate(Long rate) { + this.rate = rate; + return this; + } - public static Builder builder() { - return new Builder(); - } + /** Type of tax applied. */ + public Builder setType(String type) { + this.type = type; + return this; + } - public static class Builder { - private Long amount; + /** Type of tax applied. */ + public Builder setType(EmptyParam type) { + this.type = type; + return this; + } + } + } + } + } + } - private Object currency; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Account funding transaction details including sender and beneficiary information. */ + @SerializedName("account_funding") + Object accountFunding; - private Map extraParams; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private Object insuranceCompanyName; + /** The type of money services transaction. */ + @SerializedName("transaction_type") + ApiRequestParams.EnumParam transactionType; - private InsuranceType insuranceType; + private MoneyServices( + Object accountFunding, + Map extraParams, + ApiRequestParams.EnumParam transactionType) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + this.transactionType = transactionType; + } - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.LodgingData.Insurance build() { - return new ChargeUpdateParams.PaymentDetails.LodgingData.Insurance( - this.amount, - this.currency, - this.extraParams, - this.insuranceCompanyName, - this.insuranceType); - } + public static Builder builder() { + return new Builder(); + } - /** Required. Price of the insurance coverage in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + public static class Builder { + private Object accountFunding; - /** Currency of the insurance amount. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; - } + private Map extraParams; - /** Currency of the insurance amount. */ - public Builder setCurrency(EmptyParam currency) { - this.currency = currency; - return this; - } + private ApiRequestParams.EnumParam transactionType; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Insurance#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.MoneyServices build() { + return new ChargeUpdateParams.PaymentDetails.MoneyServices( + this.accountFunding, this.extraParams, this.transactionType); + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Insurance#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding( + ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { + this.accountFunding = accountFunding; + return this; + } - /** Name of the insurance company. */ - public Builder setInsuranceCompanyName(String insuranceCompanyName) { - this.insuranceCompanyName = insuranceCompanyName; - return this; - } + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding(EmptyParam accountFunding) { + this.accountFunding = accountFunding; + return this; + } - /** Name of the insurance company. */ - public Builder setInsuranceCompanyName(EmptyParam insuranceCompanyName) { - this.insuranceCompanyName = insuranceCompanyName; - return this; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.MoneyServices#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.put(key, value); + return this; + } - /** Required. Type of insurance coverage. */ - public Builder setInsuranceType( - ChargeUpdateParams.PaymentDetails.LodgingData.Insurance.InsuranceType insuranceType) { - this.insuranceType = insuranceType; - return this; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link ChargeUpdateParams.PaymentDetails.MoneyServices#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.putAll(map); + return this; } - public enum InsuranceType implements ApiRequestParams.EnumParam { - @SerializedName("bankruptcy") - BANKRUPTCY("bankruptcy"), - - @SerializedName("cancelation") - CANCELATION("cancelation"), - - @SerializedName("emergency") - EMERGENCY("emergency"), - - @SerializedName("medical") - MEDICAL("medical"); - - @Getter(onMethod_ = {@Override}) - private final String value; + /** The type of money services transaction. */ + public Builder setTransactionType( + ChargeUpdateParams.PaymentDetails.MoneyServices.TransactionType transactionType) { + this.transactionType = transactionType; + return this; + } - InsuranceType(String value) { - this.value = value; - } + /** The type of money services transaction. */ + public Builder setTransactionType(EmptyParam transactionType) { + this.transactionType = transactionType; + return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Total { - /** Required. Total price of the lodging reservation in cents. */ - @SerializedName("amount") - Long amount; - - /** Cash advances in cents. */ - @SerializedName("cash_advances") - Long cashAdvances; - - /** Currency of the total amount. */ - @SerializedName("currency") - Object currency; - - /** Discount details for the lodging. */ - @SerializedName("discounts") - Discounts discounts; + public static class AccountFunding { + /** ID of the Account representing the beneficiary in this account funding transaction. */ + @SerializedName("beneficiary_account") + Object beneficiaryAccount; - /** Additional charges for the lodging. */ - @SerializedName("extra_charges") - List extraCharges; + /** Inline identity details for the beneficiary of this account funding transaction. */ + @SerializedName("beneficiary_details") + Object beneficiaryDetails; /** * Map of extra parameters for custom features not available in this client library. The @@ -10959,31 +12815,25 @@ public static class Total { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Prepaid amount in cents. */ - @SerializedName("prepaid_amount") - Long prepaidAmount; + /** ID of the Account representing the sender in this account funding transaction. */ + @SerializedName("sender_account") + Object senderAccount; - /** Tax breakdown for the lodging reservation. */ - @SerializedName("tax") - Tax tax; + /** Inline identity details for the sender of this account funding transaction. */ + @SerializedName("sender_details") + Object senderDetails; - private Total( - Long amount, - Long cashAdvances, - Object currency, - Discounts discounts, - List extraCharges, + private AccountFunding( + Object beneficiaryAccount, + Object beneficiaryDetails, Map extraParams, - Long prepaidAmount, - Tax tax) { - this.amount = amount; - this.cashAdvances = cashAdvances; - this.currency = currency; - this.discounts = discounts; - this.extraCharges = extraCharges; + Object senderAccount, + Object senderDetails) { + this.beneficiaryAccount = beneficiaryAccount; + this.beneficiaryDetails = beneficiaryDetails; this.extraParams = extraParams; - this.prepaidAmount = prepaidAmount; - this.tax = tax; + this.senderAccount = senderAccount; + this.senderDetails = senderDetails; } public static Builder builder() { @@ -10991,102 +12841,58 @@ public static Builder builder() { } public static class Builder { - private Long amount; - - private Long cashAdvances; - - private Object currency; - - private Discounts discounts; - - private List - extraCharges; - - private Map extraParams; - - private Long prepaidAmount; - - private Tax tax; - - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.LodgingData.Total build() { - return new ChargeUpdateParams.PaymentDetails.LodgingData.Total( - this.amount, - this.cashAdvances, - this.currency, - this.discounts, - this.extraCharges, - this.extraParams, - this.prepaidAmount, - this.tax); - } + private Object beneficiaryAccount; - /** Required. Total price of the lodging reservation in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + private Object beneficiaryDetails; - /** Cash advances in cents. */ - public Builder setCashAdvances(Long cashAdvances) { - this.cashAdvances = cashAdvances; - return this; - } + private Map extraParams; - /** Currency of the total amount. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; + private Object senderAccount; + + private Object senderDetails; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding build() { + return new ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding( + this.beneficiaryAccount, + this.beneficiaryDetails, + this.extraParams, + this.senderAccount, + this.senderDetails); } - /** Currency of the total amount. */ - public Builder setCurrency(EmptyParam currency) { - this.currency = currency; + /** ID of the Account representing the beneficiary in this account funding transaction. */ + public Builder setBeneficiaryAccount(String beneficiaryAccount) { + this.beneficiaryAccount = beneficiaryAccount; return this; } - /** Discount details for the lodging. */ - public Builder setDiscounts( - ChargeUpdateParams.PaymentDetails.LodgingData.Total.Discounts discounts) { - this.discounts = discounts; + /** ID of the Account representing the beneficiary in this account funding transaction. */ + public Builder setBeneficiaryAccount(EmptyParam beneficiaryAccount) { + this.beneficiaryAccount = beneficiaryAccount; return this; } - /** - * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData.Total#extraCharges} for the field - * documentation. - */ - public Builder addExtraCharge( - ChargeUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge element) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.add(element); + /** Inline identity details for the beneficiary of this account funding transaction. */ + public Builder setBeneficiaryDetails( + ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails + beneficiaryDetails) { + this.beneficiaryDetails = beneficiaryDetails; return this; } - /** - * Add all elements to `extraCharges` list. A list is initialized for the first - * `add/addAll` call, and subsequent calls adds additional elements to the original list. - * See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Total#extraCharges} for the - * field documentation. - */ - public Builder addAllExtraCharge( - List elements) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.addAll(elements); + /** Inline identity details for the beneficiary of this account funding transaction. */ + public Builder setBeneficiaryDetails(EmptyParam beneficiaryDetails) { + this.beneficiaryDetails = beneficiaryDetails; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Total#extraParams} for - * the field documentation. + * map. See {@link + * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -11099,8 +12905,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.LodgingData.Total#extraParams} for - * the field documentation. + * map. See {@link + * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for the + * field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -11110,29 +12917,47 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Prepaid amount in cents. */ - public Builder setPrepaidAmount(Long prepaidAmount) { - this.prepaidAmount = prepaidAmount; + /** ID of the Account representing the sender in this account funding transaction. */ + public Builder setSenderAccount(String senderAccount) { + this.senderAccount = senderAccount; return this; } - /** Tax breakdown for the lodging reservation. */ - public Builder setTax(ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax tax) { - this.tax = tax; + /** ID of the Account representing the sender in this account funding transaction. */ + public Builder setSenderAccount(EmptyParam senderAccount) { + this.senderAccount = senderAccount; + return this; + } + + /** Inline identity details for the sender of this account funding transaction. */ + public Builder setSenderDetails( + ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + senderDetails) { + this.senderDetails = senderDetails; + return this; + } + + /** Inline identity details for the sender of this account funding transaction. */ + public Builder setSenderDetails(EmptyParam senderDetails) { + this.senderDetails = senderDetails; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Discounts { - /** Corporate client discount code. */ - @SerializedName("corporate_client_code") - Object corporateClientCode; + public static class BeneficiaryDetails { + /** Address. */ + @SerializedName("address") + Address address; - /** Coupon code. */ - @SerializedName("coupon") - Object coupon; + /** Date of birth. */ + @SerializedName("date_of_birth") + DateOfBirth dateOfBirth; + + /** Email address. */ + @SerializedName("email") + Object email; /** * Map of extra parameters for custom features not available in this client library. The @@ -11144,11 +12969,27 @@ public static class Discounts { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private Discounts( - Object corporateClientCode, Object coupon, Map extraParams) { - this.corporateClientCode = corporateClientCode; - this.coupon = coupon; + /** Full name. */ + @SerializedName("name") + Object name; + + /** Phone number. */ + @SerializedName("phone") + Object phone; + + private BeneficiaryDetails( + Address address, + DateOfBirth dateOfBirth, + Object email, + Map extraParams, + Object name, + Object phone) { + this.address = address; + this.dateOfBirth = dateOfBirth; + this.email = email; this.extraParams = extraParams; + this.name = name; + this.phone = phone; } public static Builder builder() { @@ -11156,39 +12997,58 @@ public static Builder builder() { } public static class Builder { - private Object corporateClientCode; + private Address address; - private Object coupon; + private DateOfBirth dateOfBirth; + + private Object email; private Map extraParams; + private Object name; + + private Object phone; + /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.LodgingData.Total.Discounts build() { - return new ChargeUpdateParams.PaymentDetails.LodgingData.Total.Discounts( - this.corporateClientCode, this.coupon, this.extraParams); + public ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails + build() { + return new ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails( + this.address, + this.dateOfBirth, + this.email, + this.extraParams, + this.name, + this.phone); } - /** Corporate client discount code. */ - public Builder setCorporateClientCode(String corporateClientCode) { - this.corporateClientCode = corporateClientCode; + /** Address. */ + public Builder setAddress( + ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails + .Address + address) { + this.address = address; return this; } - /** Corporate client discount code. */ - public Builder setCorporateClientCode(EmptyParam corporateClientCode) { - this.corporateClientCode = corporateClientCode; + /** Date of birth. */ + public Builder setDateOfBirth( + ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails + .DateOfBirth + dateOfBirth) { + this.dateOfBirth = dateOfBirth; return this; } - /** Coupon code. */ - public Builder setCoupon(String coupon) { - this.coupon = coupon; + /** Email address. */ + public Builder setEmail(String email) { + this.email = email; return this; } - /** Coupon code. */ - public Builder setCoupon(EmptyParam coupon) { - this.coupon = coupon; + /** Email address. */ + public Builder setEmail(EmptyParam email) { + this.email = email; return this; } @@ -11196,8 +13056,8 @@ public Builder setCoupon(EmptyParam coupon) { * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} for the - * field documentation. + * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -11211,8 +13071,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} for the - * field documentation. + * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -11221,128 +13081,362 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } + + /** Full name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** Full name. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } + + /** Phone number. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } + + /** Phone number. */ + public Builder setPhone(EmptyParam phone) { + this.phone = phone; + return this; + } } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class ExtraCharge { - /** Amount of the extra charge in cents. */ - @SerializedName("amount") - Long amount; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Address { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + Object city; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + Object country; - /** Type of extra charge. */ - @SerializedName("type") - Type type; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Address line 1, such as the street, PO Box, or company name. */ + @SerializedName("line1") + Object line1; + + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + Object line2; + + /** ZIP or postal code. */ + @SerializedName("postal_code") + Object postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + Object state; + + private Address( + Object city, + Object country, + Map extraParams, + Object line1, + Object line2, + Object postalCode, + Object state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object city; + + private Object country; + + private Map extraParams; + + private Object line1; + + private Object line2; + + private Object postalCode; + + private Object state; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.Address + build() { + return new ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } + + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** City, district, suburb, town, or village. */ + public Builder setCity(EmptyParam city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(EmptyParam country) { + this.country = country; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.Address#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.Address#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - private ExtraCharge(Long amount, Map extraParams, Type type) { - this.amount = amount; - this.extraParams = extraParams; - this.type = type; - } + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } - public static Builder builder() { - return new Builder(); - } + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(EmptyParam line1) { + this.line1 = line1; + return this; + } - public static class Builder { - private Long amount; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } - private Map extraParams; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(EmptyParam line2) { + this.line2 = line2; + return this; + } - private Type type; + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge build() { - return new ChargeUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge( - this.amount, this.extraParams, this.type); - } + /** ZIP or postal code. */ + public Builder setPostalCode(EmptyParam postalCode) { + this.postalCode = postalCode; + return this; + } - /** Amount of the extra charge in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(EmptyParam state) { + this.state = state; + return this; } - this.extraParams.put(key, value); - return this; } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class DateOfBirth { + /** Required. Day of birth, between 1 and 31. */ + @SerializedName("day") + Long day; /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} for the - * field documentation. + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Required. Month of birth, between 1 and 12. */ + @SerializedName("month") + Long month; + + /** Required. Four-digit year of birth. */ + @SerializedName("year") + Long year; + + private DateOfBirth(Long day, Map extraParams, Long month, Long year) { + this.day = day; + this.extraParams = extraParams; + this.month = month; + this.year = year; } - /** Type of extra charge. */ - public Builder setType( - ChargeUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge.Type type) { - this.type = type; - return this; + public static Builder builder() { + return new Builder(); } - } - public enum Type implements ApiRequestParams.EnumParam { - @SerializedName("gift_shop") - GIFT_SHOP("gift_shop"), + public static class Builder { + private Long day; - @SerializedName("laundry") - LAUNDRY("laundry"), + private Map extraParams; - @SerializedName("mini_bar") - MINI_BAR("mini_bar"), + private Long month; - @SerializedName("other") - OTHER("other"), + private Long year; - @SerializedName("phone") - PHONE("phone"), + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.DateOfBirth + build() { + return new ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.DateOfBirth( + this.day, this.extraParams, this.month, this.year); + } - @SerializedName("restaurant") - RESTAURANT("restaurant"); + /** Required. Day of birth, between 1 and 31. */ + public Builder setDay(Long day) { + this.day = day; + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - Type(String value) { - this.value = value; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Required. Month of birth, between 1 and 12. */ + public Builder setMonth(Long month) { + this.month = month; + return this; + } + + /** Required. Four-digit year of birth. */ + public Builder setYear(Long year) { + this.year = year; + return this; + } } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Tax { + public static class SenderDetails { + /** Address. */ + @SerializedName("address") + Address address; + + /** Date of birth. */ + @SerializedName("date_of_birth") + DateOfBirth dateOfBirth; + + /** Email address. */ + @SerializedName("email") + Object email; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -11353,21 +13447,27 @@ public static class Tax { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Indicates whether the transaction is tax exempt. */ - @SerializedName("tax_exempt_indicator") - Boolean taxExemptIndicator; + /** Full name. */ + @SerializedName("name") + Object name; - /** Tax details. */ - @SerializedName("taxes") - List taxes; + /** Phone number. */ + @SerializedName("phone") + Object phone; - private Tax( + private SenderDetails( + Address address, + DateOfBirth dateOfBirth, + Object email, Map extraParams, - Boolean taxExemptIndicator, - List taxes) { + Object name, + Object phone) { + this.address = address; + this.dateOfBirth = dateOfBirth; + this.email = email; this.extraParams = extraParams; - this.taxExemptIndicator = taxExemptIndicator; - this.taxes = taxes; + this.name = name; + this.phone = phone; } public static Builder builder() { @@ -11375,24 +13475,66 @@ public static Builder builder() { } public static class Builder { + private Address address; + + private DateOfBirth dateOfBirth; + + private Object email; + private Map extraParams; - private Boolean taxExemptIndicator; + private Object name; - private List taxes; + private Object phone; /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax build() { - return new ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax( - this.extraParams, this.taxExemptIndicator, this.taxes); + public ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + build() { + return new ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails( + this.address, + this.dateOfBirth, + this.email, + this.extraParams, + this.name, + this.phone); + } + + /** Address. */ + public Builder setAddress( + ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.Address + address) { + this.address = address; + return this; + } + + /** Date of birth. */ + public Builder setDateOfBirth( + ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + .DateOfBirth + dateOfBirth) { + this.dateOfBirth = dateOfBirth; + return this; + } + + /** Email address. */ + public Builder setEmail(String email) { + this.email = email; + return this; + } + + /** Email address. */ + public Builder setEmail(EmptyParam email) { + this.email = email; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the field - * documentation. + * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -11406,8 +13548,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the field - * documentation. + * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -11417,49 +13559,44 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Indicates whether the transaction is tax exempt. */ - public Builder setTaxExemptIndicator(Boolean taxExemptIndicator) { - this.taxExemptIndicator = taxExemptIndicator; + /** Full name. */ + public Builder setName(String name) { + this.name = name; return this; } - /** - * Add an element to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addTax( - ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax element) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.add(element); + /** Full name. */ + public Builder setName(EmptyParam name) { + this.name = name; return this; } - /** - * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addAllTax( - List elements) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.addAll(elements); + /** Phone number. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } + + /** Phone number. */ + public Builder setPhone(EmptyParam phone) { + this.phone = phone; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class InnerTax { - /** Tax amount in cents. */ - @SerializedName("amount") - Long amount; + public static class Address { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + Object city; + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + Object country; /** * Map of extra parameters for custom features not available in this client library. The @@ -11471,19 +13608,40 @@ public static class InnerTax { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Tax rate. */ - @SerializedName("rate") - Long rate; + /** Address line 1, such as the street, PO Box, or company name. */ + @SerializedName("line1") + Object line1; + + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + Object line2; - /** Type of tax applied. */ - @SerializedName("type") - Object type; + /** ZIP or postal code. */ + @SerializedName("postal_code") + Object postalCode; - private InnerTax(Long amount, Map extraParams, Long rate, Object type) { - this.amount = amount; + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + Object state; + + private Address( + Object city, + Object country, + Map extraParams, + Object line1, + Object line2, + Object postalCode, + Object state) { + this.city = city; + this.country = country; this.extraParams = extraParams; - this.rate = rate; - this.type = type; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; } public static Builder builder() { @@ -11491,23 +13649,62 @@ public static Builder builder() { } public static class Builder { - private Long amount; + private Object city; + + private Object country; private Map extraParams; - private Long rate; + private Object line1; - private Object type; + private Object line2; + + private Object postalCode; + + private Object state; /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax build() { - return new ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax( - this.amount, this.extraParams, this.rate, this.type); + public ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + .Address + build() { + return new ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); } - /** Tax amount in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** City, district, suburb, town, or village. */ + public Builder setCity(EmptyParam city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(EmptyParam country) { + this.country = country; return this; } @@ -11515,8 +13712,8 @@ public Builder setAmount(Long amount) { * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} for - * the field documentation. + * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.Address#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -11530,8 +13727,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the * first `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * ChargeUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} for - * the field documentation. + * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.Address#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -11541,180 +13738,163 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Tax rate. */ - public Builder setRate(Long rate) { - this.rate = rate; + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(String line1) { + this.line1 = line1; return this; } - /** Type of tax applied. */ - public Builder setType(String type) { - this.type = type; + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(EmptyParam line1) { + this.line1 = line1; return this; } - /** Type of tax applied. */ - public Builder setType(EmptyParam type) { - this.type = type; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; return this; } - } - } - } - } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class MoneyServices { - /** Account funding transaction details including sender and beneficiary information. */ - @SerializedName("account_funding") - Object accountFunding; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(EmptyParam line2) { + this.line2 = line2; + return this; + } - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) - * name in this param object. Effectively, this map is flattened to its parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - /** The type of money services transaction. */ - @SerializedName("transaction_type") - TransactionType transactionType; + /** ZIP or postal code. */ + public Builder setPostalCode(EmptyParam postalCode) { + this.postalCode = postalCode; + return this; + } - private MoneyServices( - Object accountFunding, Map extraParams, TransactionType transactionType) { - this.accountFunding = accountFunding; - this.extraParams = extraParams; - this.transactionType = transactionType; - } + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } - public static Builder builder() { - return new Builder(); - } + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(EmptyParam state) { + this.state = state; + return this; + } + } + } - public static class Builder { - private Object accountFunding; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class DateOfBirth { + /** Required. Day of birth, between 1 and 31. */ + @SerializedName("day") + Long day; - private Map extraParams; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private TransactionType transactionType; + /** Required. Month of birth, between 1 and 12. */ + @SerializedName("month") + Long month; - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.MoneyServices build() { - return new ChargeUpdateParams.PaymentDetails.MoneyServices( - this.accountFunding, this.extraParams, this.transactionType); - } + /** Required. Four-digit year of birth. */ + @SerializedName("year") + Long year; - /** Account funding transaction details including sender and beneficiary information. */ - public Builder setAccountFunding( - ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { - this.accountFunding = accountFunding; - return this; - } + private DateOfBirth(Long day, Map extraParams, Long month, Long year) { + this.day = day; + this.extraParams = extraParams; + this.month = month; + this.year = year; + } - /** Account funding transaction details including sender and beneficiary information. */ - public Builder setAccountFunding(EmptyParam accountFunding) { - this.accountFunding = accountFunding; - return this; - } + public static Builder builder() { + return new Builder(); + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.MoneyServices#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + public static class Builder { + private Long day; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link ChargeUpdateParams.PaymentDetails.MoneyServices#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + private Map extraParams; - /** The type of money services transaction. */ - public Builder setTransactionType( - ChargeUpdateParams.PaymentDetails.MoneyServices.TransactionType transactionType) { - this.transactionType = transactionType; - return this; - } - } + private Long month; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class AccountFunding { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private Long year; - private AccountFunding(Map extraParams) { - this.extraParams = extraParams; - } + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + .DateOfBirth + build() { + return new ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.DateOfBirth(this.day, this.extraParams, this.month, this.year); + } - public static Builder builder() { - return new Builder(); - } + /** Required. Day of birth, between 1 and 31. */ + public Builder setDay(Long day) { + this.day = day; + return this; + } - public static class Builder { - private Map extraParams; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** Finalize and obtain parameter instance from this builder. */ - public ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding build() { - return new ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding( - this.extraParams); - } + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Required. Month of birth, between 1 and 12. */ + public Builder setMonth(Long month) { + this.month = month; + return this; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** Required. Four-digit year of birth. */ + public Builder setYear(Long year) { + this.year = year; + return this; + } } - this.extraParams.putAll(map); - return this; } } } diff --git a/src/main/java/com/stripe/param/InvoiceCreateParams.java b/src/main/java/com/stripe/param/InvoiceCreateParams.java index 1755bd8a1c2..1eb8496f122 100644 --- a/src/main/java/com/stripe/param/InvoiceCreateParams.java +++ b/src/main/java/com/stripe/param/InvoiceCreateParams.java @@ -2196,6 +2196,13 @@ public static class PaymentMethodOptions { @SerializedName("bancontact") Object bancontact; + /** + * If paying by {@code bizum}, this sub-hash contains details about the Bizum payment method + * options to pass to the invoice’s PaymentIntent. + */ + @SerializedName("bizum") + Object bizum; + /** * If paying by {@code card}, this sub-hash contains details about the Card payment method * options to pass to the invoice’s PaymentIntent. @@ -2278,6 +2285,7 @@ public static class PaymentMethodOptions { private PaymentMethodOptions( Object acssDebit, Object bancontact, + Object bizum, Object card, Object checkScan, Object customerBalance, @@ -2291,6 +2299,7 @@ private PaymentMethodOptions( Object usBankAccount) { this.acssDebit = acssDebit; this.bancontact = bancontact; + this.bizum = bizum; this.card = card; this.checkScan = checkScan; this.customerBalance = customerBalance; @@ -2313,6 +2322,8 @@ public static class Builder { private Object bancontact; + private Object bizum; + private Object card; private Object checkScan; @@ -2340,6 +2351,7 @@ public InvoiceCreateParams.PaymentSettings.PaymentMethodOptions build() { return new InvoiceCreateParams.PaymentSettings.PaymentMethodOptions( this.acssDebit, this.bancontact, + this.bizum, this.card, this.checkScan, this.customerBalance, @@ -2391,6 +2403,25 @@ public Builder setBancontact(EmptyParam bancontact) { return this; } + /** + * If paying by {@code bizum}, this sub-hash contains details about the Bizum payment method + * options to pass to the invoice’s PaymentIntent. + */ + public Builder setBizum( + InvoiceCreateParams.PaymentSettings.PaymentMethodOptions.Bizum bizum) { + this.bizum = bizum; + return this; + } + + /** + * If paying by {@code bizum}, this sub-hash contains details about the Bizum payment method + * options to pass to the invoice’s PaymentIntent. + */ + public Builder setBizum(EmptyParam bizum) { + this.bizum = bizum; + return this; + } + /** * If paying by {@code card}, this sub-hash contains details about the Card payment method * options to pass to the invoice’s PaymentIntent. @@ -2920,6 +2951,68 @@ public enum PreferredLanguage implements ApiRequestParams.EnumParam { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Bizum { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Bizum(Map extraParams) { + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public InvoiceCreateParams.PaymentSettings.PaymentMethodOptions.Bizum build() { + return new InvoiceCreateParams.PaymentSettings.PaymentMethodOptions.Bizum( + this.extraParams); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * InvoiceCreateParams.PaymentSettings.PaymentMethodOptions.Bizum#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * InvoiceCreateParams.PaymentSettings.PaymentMethodOptions.Bizum#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class Card { @@ -5120,6 +5213,9 @@ public enum PaymentMethodType implements ApiRequestParams.EnumParam { @SerializedName("bancontact") BANCONTACT("bancontact"), + @SerializedName("bizum") + BIZUM("bizum"), + @SerializedName("boleto") BOLETO("boleto"), diff --git a/src/main/java/com/stripe/param/InvoiceUpdateParams.java b/src/main/java/com/stripe/param/InvoiceUpdateParams.java index 4dcbe1c385e..4679b210678 100644 --- a/src/main/java/com/stripe/param/InvoiceUpdateParams.java +++ b/src/main/java/com/stripe/param/InvoiceUpdateParams.java @@ -2190,6 +2190,13 @@ public static class PaymentMethodOptions { @SerializedName("bancontact") Object bancontact; + /** + * If paying by {@code bizum}, this sub-hash contains details about the Bizum payment method + * options to pass to the invoice’s PaymentIntent. + */ + @SerializedName("bizum") + Object bizum; + /** * If paying by {@code card}, this sub-hash contains details about the Card payment method * options to pass to the invoice’s PaymentIntent. @@ -2272,6 +2279,7 @@ public static class PaymentMethodOptions { private PaymentMethodOptions( Object acssDebit, Object bancontact, + Object bizum, Object card, Object checkScan, Object customerBalance, @@ -2285,6 +2293,7 @@ private PaymentMethodOptions( Object usBankAccount) { this.acssDebit = acssDebit; this.bancontact = bancontact; + this.bizum = bizum; this.card = card; this.checkScan = checkScan; this.customerBalance = customerBalance; @@ -2307,6 +2316,8 @@ public static class Builder { private Object bancontact; + private Object bizum; + private Object card; private Object checkScan; @@ -2334,6 +2345,7 @@ public InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions build() { return new InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions( this.acssDebit, this.bancontact, + this.bizum, this.card, this.checkScan, this.customerBalance, @@ -2385,6 +2397,25 @@ public Builder setBancontact(EmptyParam bancontact) { return this; } + /** + * If paying by {@code bizum}, this sub-hash contains details about the Bizum payment method + * options to pass to the invoice’s PaymentIntent. + */ + public Builder setBizum( + InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions.Bizum bizum) { + this.bizum = bizum; + return this; + } + + /** + * If paying by {@code bizum}, this sub-hash contains details about the Bizum payment method + * options to pass to the invoice’s PaymentIntent. + */ + public Builder setBizum(EmptyParam bizum) { + this.bizum = bizum; + return this; + } + /** * If paying by {@code card}, this sub-hash contains details about the Card payment method * options to pass to the invoice’s PaymentIntent. @@ -2914,6 +2945,68 @@ public enum PreferredLanguage implements ApiRequestParams.EnumParam { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Bizum { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Bizum(Map extraParams) { + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions.Bizum build() { + return new InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions.Bizum( + this.extraParams); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions.Bizum#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions.Bizum#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class Card { @@ -5188,6 +5281,9 @@ public enum PaymentMethodType implements ApiRequestParams.EnumParam { @SerializedName("bancontact") BANCONTACT("bancontact"), + @SerializedName("bizum") + BIZUM("bizum"), + @SerializedName("boleto") BOLETO("boleto"), diff --git a/src/main/java/com/stripe/param/PaymentIntentCaptureParams.java b/src/main/java/com/stripe/param/PaymentIntentCaptureParams.java index 15d3a6a8239..e130da3268d 100644 --- a/src/main/java/com/stripe/param/PaymentIntentCaptureParams.java +++ b/src/main/java/com/stripe/param/PaymentIntentCaptureParams.java @@ -687,6 +687,13 @@ public static class LineItem { @SerializedName("quantity") Long quantity; + /** + * The number of decimal places implied in the quantity. For example, if quantity is 10000 and + * quantity_precision is 2, the actual quantity is 100.00. Defaults to 0 if not provided. + */ + @SerializedName("quantity_precision") + Long quantityPrecision; + /** Contains information about the tax on the item. */ @SerializedName("tax") Tax tax; @@ -710,6 +717,7 @@ private LineItem( String productCode, String productName, Long quantity, + Long quantityPrecision, Tax tax, Long unitCost, String unitOfMeasure) { @@ -719,6 +727,7 @@ private LineItem( this.productCode = productCode; this.productName = productName; this.quantity = quantity; + this.quantityPrecision = quantityPrecision; this.tax = tax; this.unitCost = unitCost; this.unitOfMeasure = unitOfMeasure; @@ -741,6 +750,8 @@ public static class Builder { private Long quantity; + private Long quantityPrecision; + private Tax tax; private Long unitCost; @@ -756,6 +767,7 @@ public PaymentIntentCaptureParams.AmountDetails.LineItem build() { this.productCode, this.productName, this.quantity, + this.quantityPrecision, this.tax, this.unitCost, this.unitOfMeasure); @@ -840,6 +852,16 @@ public Builder setQuantity(Long quantity) { return this; } + /** + * The number of decimal places implied in the quantity. For example, if quantity is 10000 + * and quantity_precision is 2, the actual quantity is 100.00. Defaults to 0 if not + * provided. + */ + public Builder setQuantityPrecision(Long quantityPrecision) { + this.quantityPrecision = quantityPrecision; + return this; + } + /** Contains information about the tax on the item. */ public Builder setTax(PaymentIntentCaptureParams.AmountDetails.LineItem.Tax tax) { this.tax = tax; @@ -1032,9 +1054,14 @@ public static class Card { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private Card(String commodityCode, Map extraParams) { + /** Fleet data for this line item. */ + @SerializedName("fleet_data") + FleetData fleetData; + + private Card(String commodityCode, Map extraParams, FleetData fleetData) { this.commodityCode = commodityCode; this.extraParams = extraParams; + this.fleetData = fleetData; } public static Builder builder() { @@ -1046,11 +1073,13 @@ public static class Builder { private Map extraParams; + private FleetData fleetData; + /** Finalize and obtain parameter instance from this builder. */ public PaymentIntentCaptureParams.AmountDetails.LineItem.PaymentMethodOptions.Card build() { return new PaymentIntentCaptureParams.AmountDetails.LineItem.PaymentMethodOptions - .Card(this.commodityCode, this.extraParams); + .Card(this.commodityCode, this.extraParams, this.fleetData); } /** @@ -1091,6 +1120,267 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } + + /** Fleet data for this line item. */ + public Builder setFleetData( + PaymentIntentCaptureParams.AmountDetails.LineItem.PaymentMethodOptions.Card + .FleetData + fleetData) { + this.fleetData = fleetData; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class FleetData { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Required. The type of product being purchased at this line item. */ + @SerializedName("product_type") + ProductType productType; + + /** The type of service received at the acceptor location. */ + @SerializedName("service_type") + ServiceType serviceType; + + private FleetData( + Map extraParams, ProductType productType, ServiceType serviceType) { + this.extraParams = extraParams; + this.productType = productType; + this.serviceType = serviceType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private ProductType productType; + + private ServiceType serviceType; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.AmountDetails.LineItem.PaymentMethodOptions.Card + .FleetData + build() { + return new PaymentIntentCaptureParams.AmountDetails.LineItem.PaymentMethodOptions + .Card.FleetData(this.extraParams, this.productType, this.serviceType); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.AmountDetails.LineItem.PaymentMethodOptions.Card.FleetData#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.AmountDetails.LineItem.PaymentMethodOptions.Card.FleetData#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. The type of product being purchased at this line item. + */ + public Builder setProductType( + PaymentIntentCaptureParams.AmountDetails.LineItem.PaymentMethodOptions.Card + .FleetData.ProductType + productType) { + this.productType = productType; + return this; + } + + /** The type of service received at the acceptor location. */ + public Builder setServiceType( + PaymentIntentCaptureParams.AmountDetails.LineItem.PaymentMethodOptions.Card + .FleetData.ServiceType + serviceType) { + this.serviceType = serviceType; + return this; + } + } + + public enum ProductType implements ApiRequestParams.EnumParam { + @SerializedName("air_conditioning_service") + AIR_CONDITIONING_SERVICE("air_conditioning_service"), + + @SerializedName("alcohol") + ALCOHOL("alcohol"), + + @SerializedName("aviation_fuel_premium") + AVIATION_FUEL_PREMIUM("aviation_fuel_premium"), + + @SerializedName("aviation_fuel_regular") + AVIATION_FUEL_REGULAR("aviation_fuel_regular"), + + @SerializedName("car_care_detailing") + CAR_CARE_DETAILING("car_care_detailing"), + + @SerializedName("compressed_natural_gas") + COMPRESSED_NATURAL_GAS("compressed_natural_gas"), + + @SerializedName("deli") + DELI("deli"), + + @SerializedName("food_service") + FOOD_SERVICE("food_service"), + + @SerializedName("green_gasoline_mid_plus") + GREEN_GASOLINE_MID_PLUS("green_gasoline_mid_plus"), + + @SerializedName("green_gasoline_premium_super") + GREEN_GASOLINE_PREMIUM_SUPER("green_gasoline_premium_super"), + + @SerializedName("green_gasoline_regular") + GREEN_GASOLINE_REGULAR("green_gasoline_regular"), + + @SerializedName("grocery") + GROCERY("grocery"), + + @SerializedName("liquid_natural_gas") + LIQUID_NATURAL_GAS("liquid_natural_gas"), + + @SerializedName("liquid_propane_gas") + LIQUID_PROPANE_GAS("liquid_propane_gas"), + + @SerializedName("lodging") + LODGING("lodging"), + + @SerializedName("marine_diesel") + MARINE_DIESEL("marine_diesel"), + + @SerializedName("marine_fuel") + MARINE_FUEL("marine_fuel"), + + @SerializedName("merchandise") + MERCHANDISE("merchandise"), + + @SerializedName("mid_plus") + MID_PLUS("mid_plus"), + + @SerializedName("mid_plus_ethanol") + MID_PLUS_ETHANOL("mid_plus_ethanol"), + + @SerializedName("miscellaneous_aviation_products_services") + MISCELLANEOUS_AVIATION_PRODUCTS_SERVICES("miscellaneous_aviation_products_services"), + + @SerializedName("miscellaneous_fuel") + MISCELLANEOUS_FUEL("miscellaneous_fuel"), + + @SerializedName("miscellaneous_marine_products_services") + MISCELLANEOUS_MARINE_PRODUCTS_SERVICES("miscellaneous_marine_products_services"), + + @SerializedName("miscellaneous_vehicle_products_services") + MISCELLANEOUS_VEHICLE_PRODUCTS_SERVICES("miscellaneous_vehicle_products_services"), + + @SerializedName("packaged_beverage") + PACKAGED_BEVERAGE("packaged_beverage"), + + @SerializedName("premium_diesel") + PREMIUM_DIESEL("premium_diesel"), + + @SerializedName("premium_super") + PREMIUM_SUPER("premium_super"), + + @SerializedName("premium_super_ethanol") + PREMIUM_SUPER_ETHANOL("premium_super_ethanol"), + + @SerializedName("preventative_maintenance") + PREVENTATIVE_MAINTENANCE("preventative_maintenance"), + + @SerializedName("regular") + REGULAR("regular"), + + @SerializedName("regular_diesel") + REGULAR_DIESEL("regular_diesel"), + + @SerializedName("regular_ethanol") + REGULAR_ETHANOL("regular_ethanol"), + + @SerializedName("repairs") + REPAIRS("repairs"), + + @SerializedName("self_service_car_wash") + SELF_SERVICE_CAR_WASH("self_service_car_wash"), + + @SerializedName("shower") + SHOWER("shower"), + + @SerializedName("store_service") + STORE_SERVICE("store_service"), + + @SerializedName("tobacco") + TOBACCO("tobacco"), + + @SerializedName("vehicle_accessories") + VEHICLE_ACCESSORIES("vehicle_accessories"), + + @SerializedName("vehicle_parking") + VEHICLE_PARKING("vehicle_parking"), + + @SerializedName("vehicle_parts") + VEHICLE_PARTS("vehicle_parts"), + + @SerializedName("wash_out") + WASH_OUT("wash_out"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ProductType(String value) { + this.value = value; + } + } + + public enum ServiceType implements ApiRequestParams.EnumParam { + @SerializedName("full_service") + FULL_SERVICE("full_service"), + + @SerializedName("high_speed_diesel") + HIGH_SPEED_DIESEL("high_speed_diesel"), + + @SerializedName("non_fuel_only") + NON_FUEL_ONLY("non_fuel_only"), + + @SerializedName("self_service") + SELF_SERVICE("self_service"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ServiceType(String value) { + this.value = value; + } + } } } @@ -2142,6 +2432,10 @@ public static class PaymentDetails { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; + /** Fleet data for this PaymentIntent. */ + @SerializedName("fleet_data") + Object fleetData; + /** Flight reservation details for this PaymentIntent. */ @SerializedName("flight") Flight flight; @@ -2183,6 +2477,7 @@ private PaymentDetails( Object customerReference, EventDetails eventDetails, Map extraParams, + Object fleetData, Flight flight, Object flightData, Lodging lodging, @@ -2195,6 +2490,7 @@ private PaymentDetails( this.customerReference = customerReference; this.eventDetails = eventDetails; this.extraParams = extraParams; + this.fleetData = fleetData; this.flight = flight; this.flightData = flightData; this.lodging = lodging; @@ -2219,6 +2515,8 @@ public static class Builder { private Map extraParams; + private Object fleetData; + private Flight flight; private Object flightData; @@ -2241,6 +2539,7 @@ public PaymentIntentCaptureParams.PaymentDetails build() { this.customerReference, this.eventDetails, this.extraParams, + this.fleetData, this.flight, this.flightData, this.lodging, @@ -2359,6 +2658,49 @@ public Builder putAllExtraParam(Map map) { return this; } + /** + * Add an element to `fleetData` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCaptureParams.PaymentDetails#fleetData} for the field documentation. + */ + @SuppressWarnings("unchecked") + public Builder addFleetData(PaymentIntentCaptureParams.PaymentDetails.FleetData element) { + if (this.fleetData == null || this.fleetData instanceof EmptyParam) { + this.fleetData = new ArrayList(); + } + ((List) this.fleetData).add(element); + return this; + } + + /** + * Add all elements to `fleetData` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCaptureParams.PaymentDetails#fleetData} for the field documentation. + */ + @SuppressWarnings("unchecked") + public Builder addAllFleetData( + List elements) { + if (this.fleetData == null || this.fleetData instanceof EmptyParam) { + this.fleetData = new ArrayList(); + } + ((List) this.fleetData) + .addAll(elements); + return this; + } + + /** Fleet data for this PaymentIntent. */ + public Builder setFleetData(EmptyParam fleetData) { + this.fleetData = fleetData; + return this; + } + + /** Fleet data for this PaymentIntent. */ + public Builder setFleetData( + List fleetData) { + this.fleetData = fleetData; + return this; + } + /** Flight reservation details for this PaymentIntent. */ public Builder setFlight(PaymentIntentCaptureParams.PaymentDetails.Flight flight) { this.flight = flight; @@ -6931,29 +7273,7 @@ public enum Mode implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class Flight { - /** Affiliate details for this purchase. */ - @SerializedName("affiliate") - Affiliate affiliate; - - /** - * The agency number (i.e. International Air Transport Association (IATA) agency number) of - * the travel agency that made the booking. - */ - @SerializedName("agency_number") - String agencyNumber; - - /** - * The International Air Transport Association (IATA) carrier code of the carrier that issued - * the ticket. - */ - @SerializedName("carrier") - String carrier; - - /** Delivery details for this purchase. */ - @SerializedName("delivery") - Delivery delivery; - + public static class FleetData { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -6963,41 +7283,27 @@ public static class Flight { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** The name of the person or entity on the reservation. */ - @SerializedName("passenger_name") - String passengerName; - - /** The details of the passengers in the travel reservation. */ - @SerializedName("passengers") - List passengers; + /** Primary fuel fields for the transaction. */ + @SerializedName("primary_fuel_fields") + PrimaryFuelFields primaryFuelFields; - /** Required. The individual flight segments associated with the trip. */ - @SerializedName("segments") - List segments; + /** Station and acceptor location details. */ + @SerializedName("station") + Station station; - /** The ticket number associated with the travel reservation. */ - @SerializedName("ticket_number") - String ticketNumber; + /** VAT and Invoice on Behalf (IOB) details. */ + @SerializedName("vat") + Vat vat; - private Flight( - Affiliate affiliate, - String agencyNumber, - String carrier, - Delivery delivery, + private FleetData( Map extraParams, - String passengerName, - List passengers, - List segments, - String ticketNumber) { - this.affiliate = affiliate; - this.agencyNumber = agencyNumber; - this.carrier = carrier; - this.delivery = delivery; + PrimaryFuelFields primaryFuelFields, + Station station, + Vat vat) { this.extraParams = extraParams; - this.passengerName = passengerName; - this.passengers = passengers; - this.segments = segments; - this.ticketNumber = ticketNumber; + this.primaryFuelFields = primaryFuelFields; + this.station = station; + this.vat = vat; } public static Builder builder() { @@ -7005,88 +7311,38 @@ public static Builder builder() { } public static class Builder { - private Affiliate affiliate; - - private String agencyNumber; - - private String carrier; - - private Delivery delivery; - private Map extraParams; - private String passengerName; - - private List passengers; + private PrimaryFuelFields primaryFuelFields; - private List segments; + private Station station; - private String ticketNumber; + private Vat vat; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.Flight build() { - return new PaymentIntentCaptureParams.PaymentDetails.Flight( - this.affiliate, - this.agencyNumber, - this.carrier, - this.delivery, - this.extraParams, - this.passengerName, - this.passengers, - this.segments, - this.ticketNumber); - } - - /** Affiliate details for this purchase. */ - public Builder setAffiliate( - PaymentIntentCaptureParams.PaymentDetails.Flight.Affiliate affiliate) { - this.affiliate = affiliate; - return this; + public PaymentIntentCaptureParams.PaymentDetails.FleetData build() { + return new PaymentIntentCaptureParams.PaymentDetails.FleetData( + this.extraParams, this.primaryFuelFields, this.station, this.vat); } /** - * The agency number (i.e. International Air Transport Association (IATA) agency number) of - * the travel agency that made the booking. + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.FleetData#extraParams} for the + * field documentation. */ - public Builder setAgencyNumber(String agencyNumber) { - this.agencyNumber = agencyNumber; - return this; - } - - /** - * The International Air Transport Association (IATA) carrier code of the carrier that - * issued the ticket. - */ - public Builder setCarrier(String carrier) { - this.carrier = carrier; - return this; - } - - /** Delivery details for this purchase. */ - public Builder setDelivery( - PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery delivery) { - this.delivery = delivery; - return this; - } - - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); return this; } /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight#extraParams} for the + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.FleetData#extraParams} for the * field documentation. */ public Builder putAllExtraParam(Map map) { @@ -7097,78 +7353,35 @@ public Builder putAllExtraParam(Map map) { return this; } - /** The name of the person or entity on the reservation. */ - public Builder setPassengerName(String passengerName) { - this.passengerName = passengerName; - return this; - } - - /** - * Add an element to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCaptureParams.PaymentDetails.Flight#passengers} for the field documentation. - */ - public Builder addPassenger( - PaymentIntentCaptureParams.PaymentDetails.Flight.Passenger element) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.add(element); - return this; - } - - /** - * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCaptureParams.PaymentDetails.Flight#passengers} for the field documentation. - */ - public Builder addAllPassenger( - List elements) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.addAll(elements); - return this; - } - - /** - * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCaptureParams.PaymentDetails.Flight#segments} for the field documentation. - */ - public Builder addSegment( - PaymentIntentCaptureParams.PaymentDetails.Flight.Segment element) { - if (this.segments == null) { - this.segments = new ArrayList<>(); - } - this.segments.add(element); + /** Primary fuel fields for the transaction. */ + public Builder setPrimaryFuelFields( + PaymentIntentCaptureParams.PaymentDetails.FleetData.PrimaryFuelFields + primaryFuelFields) { + this.primaryFuelFields = primaryFuelFields; return this; } - /** - * Add all elements to `segments` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCaptureParams.PaymentDetails.Flight#segments} for the field documentation. - */ - public Builder addAllSegment( - List elements) { - if (this.segments == null) { - this.segments = new ArrayList<>(); - } - this.segments.addAll(elements); + /** Station and acceptor location details. */ + public Builder setStation( + PaymentIntentCaptureParams.PaymentDetails.FleetData.Station station) { + this.station = station; return this; } - /** The ticket number associated with the travel reservation. */ - public Builder setTicketNumber(String ticketNumber) { - this.ticketNumber = ticketNumber; + /** VAT and Invoice on Behalf (IOB) details. */ + public Builder setVat(PaymentIntentCaptureParams.PaymentDetails.FleetData.Vat vat) { + this.vat = vat; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Affiliate { + public static class PrimaryFuelFields { + /** The fuel brand. */ + @SerializedName("brand") + Brand brand; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -7179,13 +7392,9 @@ public static class Affiliate { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Required. The name of the affiliate that originated the purchase. */ - @SerializedName("name") - String name; - - private Affiliate(Map extraParams, String name) { + private PrimaryFuelFields(Brand brand, Map extraParams) { + this.brand = brand; this.extraParams = extraParams; - this.name = name; } public static Builder builder() { @@ -7193,21 +7402,29 @@ public static Builder builder() { } public static class Builder { - private Map extraParams; + private Brand brand; - private String name; + private Map extraParams; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.Flight.Affiliate build() { - return new PaymentIntentCaptureParams.PaymentDetails.Flight.Affiliate( - this.extraParams, this.name); + public PaymentIntentCaptureParams.PaymentDetails.FleetData.PrimaryFuelFields build() { + return new PaymentIntentCaptureParams.PaymentDetails.FleetData.PrimaryFuelFields( + this.brand, this.extraParams); + } + + /** The fuel brand. */ + public Builder setBrand( + PaymentIntentCaptureParams.PaymentDetails.FleetData.PrimaryFuelFields.Brand brand) { + this.brand = brand; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight.Affiliate#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FleetData.PrimaryFuelFields#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -7220,8 +7437,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight.Affiliate#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FleetData.PrimaryFuelFields#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -7230,221 +7448,409 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } - - /** Required. The name of the affiliate that originated the purchase. */ - public Builder setName(String name) { - this.name = name; - return this; - } } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Delivery { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public enum Brand implements ApiRequestParams.EnumParam { + @SerializedName("aafes") + AAFES("aafes"), - /** The delivery method for the payment. */ - @SerializedName("mode") - Mode mode; + @SerializedName("amerada_hess") + AMERADA_HESS("amerada_hess"), - /** Details of the recipient. */ - @SerializedName("recipient") - Recipient recipient; + @SerializedName("amoco_canada") + AMOCO_CANADA("amoco_canada"), - private Delivery(Map extraParams, Mode mode, Recipient recipient) { - this.extraParams = extraParams; - this.mode = mode; - this.recipient = recipient; - } + @SerializedName("amoco_petroleum_products") + AMOCO_PETROLEUM_PRODUCTS("amoco_petroleum_products"), - public static Builder builder() { - return new Builder(); - } + @SerializedName("arco_products") + ARCO_PRODUCTS("arco_products"), - public static class Builder { - private Map extraParams; + @SerializedName("asda") + ASDA("asda"), - private Mode mode; + @SerializedName("ashland_oil") + ASHLAND_OIL("ashland_oil"), - private Recipient recipient; + @SerializedName("bfl") + BFL("bfl"), - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery build() { - return new PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery( - this.extraParams, this.mode, this.recipient); - } + @SerializedName("bp_mobil") + BP_MOBIL("bp_mobil"), - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + @SerializedName("bp_oil") + BP_OIL("bp_oil"), - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + @SerializedName("burrnah_major") + BURRNAH_MAJOR("burrnah_major"), - /** The delivery method for the payment. */ - public Builder setMode( - PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery.Mode mode) { - this.mode = mode; - return this; - } + @SerializedName("butler_arndale") + BUTLER_ARNDALE("butler_arndale"), - /** Details of the recipient. */ - public Builder setRecipient( - PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery.Recipient recipient) { - this.recipient = recipient; - return this; - } - } + @SerializedName("canadian_tire") + CANADIAN_TIRE("canadian_tire"), - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Recipient { - /** The email of the recipient the ticket is delivered to. */ - @SerializedName("email") - String email; + @SerializedName("canadian_turbo") + CANADIAN_TURBO("canadian_turbo"), - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + @SerializedName("caseys_general_store") + CASEYS_GENERAL_STORE("caseys_general_store"), - /** The name of the recipient the ticket is delivered to. */ - @SerializedName("name") - String name; + @SerializedName("cenex") + CENEX("cenex"), - /** The phone number of the recipient the ticket is delivered to. */ - @SerializedName("phone") - String phone; + @SerializedName("chevron_canada") + CHEVRON_CANADA("chevron_canada"), - private Recipient( - String email, Map extraParams, String name, String phone) { - this.email = email; - this.extraParams = extraParams; - this.name = name; - this.phone = phone; - } + @SerializedName("chevron_usa") + CHEVRON_USA("chevron_usa"), - public static Builder builder() { - return new Builder(); - } + @SerializedName("circle_k_stores") + CIRCLE_K_STORES("circle_k_stores"), - public static class Builder { - private String email; + @SerializedName("citgo_petroleum") + CITGO_PETROLEUM("citgo_petroleum"), - private Map extraParams; + @SerializedName("clark_brands") + CLARK_BRANDS("clark_brands"), - private String name; + @SerializedName("conoco_canada") + CONOCO_CANADA("conoco_canada"), - private String phone; + @SerializedName("conoco_inc") + CONOCO_INC("conoco_inc"), - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery.Recipient build() { - return new PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery.Recipient( - this.email, this.extraParams, this.name, this.phone); - } + @SerializedName("crown_central_petroleum") + CROWN_CENTRAL_PETROLEUM("crown_central_petroleum"), - /** The email of the recipient the ticket is delivered to. */ - public Builder setEmail(String email) { - this.email = email; - return this; - } + @SerializedName("diamond_shamrock_inc") + DIAMOND_SHAMROCK_INC("diamond_shamrock_inc"), - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + @SerializedName("discount_tire") + DISCOUNT_TIRE("discount_tire"), - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + @SerializedName("domo_gas") + DOMO_GAS("domo_gas"), - /** The name of the recipient the ticket is delivered to. */ - public Builder setName(String name) { - this.name = name; - return this; - } + @SerializedName("elf") + ELF("elf"), - /** The phone number of the recipient the ticket is delivered to. */ - public Builder setPhone(String phone) { - this.phone = phone; - return this; - } - } - } + @SerializedName("erickson_oil") + ERICKSON_OIL("erickson_oil"), - public enum Mode implements ApiRequestParams.EnumParam { - @SerializedName("email") - EMAIL("email"), + @SerializedName("esso") + ESSO("esso"), - @SerializedName("phone") - PHONE("phone"), + @SerializedName("esso_canada") + ESSO_CANADA("esso_canada"), - @SerializedName("pickup") - PICKUP("pickup"), + @SerializedName("exxon") + EXXON("exxon"), - @SerializedName("post") - POST("post"); + @SerializedName("exxonmobil") + EXXONMOBIL("exxonmobil"), + + @SerializedName("family_express") + FAMILY_EXPRESS("family_express"), + + @SerializedName("fas_gas_oil") + FAS_GAS_OIL("fas_gas_oil"), + + @SerializedName("federated_coop_sonic") + FEDERATED_COOP_SONIC("federated_coop_sonic"), + + @SerializedName("fina") + FINA("fina"), + + @SerializedName("fina_inc") + FINA_INC("fina_inc"), + + @SerializedName("fkg_oil") + FKG_OIL("fkg_oil"), + + @SerializedName("flare") + FLARE("flare"), + + @SerializedName("flying_j_inc") + FLYING_J_INC("flying_j_inc"), + + @SerializedName("gas_america") + GAS_AMERICA("gas_america"), + + @SerializedName("gate_petroleum") + GATE_PETROLEUM("gate_petroleum"), + + @SerializedName("getty_petroleum") + GETTY_PETROLEUM("getty_petroleum"), + + @SerializedName("giant_eagle") + GIANT_EAGLE("giant_eagle"), + + @SerializedName("grow_mark_inc") + GROW_MARK_INC("grow_mark_inc"), + + @SerializedName("gulf") + GULF("gulf"), + + @SerializedName("gulf_canada") + GULF_CANADA("gulf_canada"), + + @SerializedName("gulf_chevron") + GULF_CHEVRON("gulf_chevron"), + + @SerializedName("handy_way_food") + HANDY_WAY_FOOD("handy_way_food"), + + @SerializedName("heron") + HERON("heron"), + + @SerializedName("holiday_stores") + HOLIDAY_STORES("holiday_stores"), + + @SerializedName("home_depot") + HOME_DEPOT("home_depot"), + + @SerializedName("husky") + HUSKY("husky"), + + @SerializedName("hyvees") + HYVEES("hyvees"), + + @SerializedName("irving") + IRVING("irving"), + + @SerializedName("irving_oil") + IRVING_OIL("irving_oil"), + + @SerializedName("j_sainsbury") + J_SAINSBURY("j_sainsbury"), + + @SerializedName("jet_conoco") + JET_CONOCO("jet_conoco"), + + @SerializedName("krogers") + KROGERS("krogers"), + + @SerializedName("kuwait") + KUWAIT("kuwait"), + + @SerializedName("kwik_trip_inc") + KWIK_TRIP_INC("kwik_trip_inc"), + + @SerializedName("lassus") + LASSUS("lassus"), + + @SerializedName("loves_country_stores") + LOVES_COUNTRY_STORES("loves_country_stores"), + + @SerializedName("mapco_express_inc") + MAPCO_EXPRESS_INC("mapco_express_inc"), + + @SerializedName("marathon_oil") + MARATHON_OIL("marathon_oil"), + + @SerializedName("martin_bailey_inc_dba_hucks") + MARTIN_BAILEY_INC_DBA_HUCKS("martin_bailey_inc_dba_hucks"), + + @SerializedName("maxol") + MAXOL("maxol"), + + @SerializedName("meineke") + MEINEKE("meineke"), + + @SerializedName("mfa") + MFA("mfa"), + + @SerializedName("mohawk") + MOHAWK("mohawk"), + + @SerializedName("mr_gas") + MR_GAS("mr_gas"), + + @SerializedName("murco") + MURCO("murco"), + + @SerializedName("murphy_oil_canada") + MURPHY_OIL_CANADA("murphy_oil_canada"), + + @SerializedName("murphy_oil_usa_inc") + MURPHY_OIL_USA_INC("murphy_oil_usa_inc"), + + @SerializedName("nexcom") + NEXCOM("nexcom"), + + @SerializedName("nordstrom_oil") + NORDSTROM_OIL("nordstrom_oil"), + + @SerializedName("olco") + OLCO("olco"), + + @SerializedName("pdq_store") + PDQ_STORE("pdq_store"), + + @SerializedName("pennzoil_products_inc") + PENNZOIL_PRODUCTS_INC("pennzoil_products_inc"), + + @SerializedName("petro") + PETRO("petro"), + + @SerializedName("petro_canada") + PETRO_CANADA("petro_canada"), + + @SerializedName("petro_t") + PETRO_T("petro_t"), + + @SerializedName("phillips") + PHILLIPS("phillips"), + + @SerializedName("pilot") + PILOT("pilot"), + + @SerializedName("pioneer") + PIONEER("pioneer"), + + @SerializedName("pure_oil") + PURE_OIL("pure_oil"), + + @SerializedName("quaker_state") + QUAKER_STATE("quaker_state"), + + @SerializedName("quarles_oil") + QUARLES_OIL("quarles_oil"), + + @SerializedName("quiktrip") + QUIKTRIP("quiktrip"), + + @SerializedName("racetrac_petroleum_inc") + RACETRAC_PETROLEUM_INC("racetrac_petroleum_inc"), + + @SerializedName("raceway_petroleum") + RACEWAY_PETROLEUM("raceway_petroleum"), + + @SerializedName("repsol") + REPSOL("repsol"), + + @SerializedName("rudy") + RUDY("rudy"), + + @SerializedName("safeway") + SAFEWAY("safeway"), + + @SerializedName("seven_eleven") + SEVEN_ELEVEN("seven_eleven"), + + @SerializedName("sheetz") + SHEETZ("sheetz"), + + @SerializedName("shell") + SHELL("shell"), + + @SerializedName("shell_canada") + SHELL_CANADA("shell_canada"), + + @SerializedName("shell_oil") + SHELL_OIL("shell_oil"), + + @SerializedName("sinclair_oil") + SINCLAIR_OIL("sinclair_oil"), + + @SerializedName("southland_oil") + SOUTHLAND_OIL("southland_oil"), + + @SerializedName("spar") + SPAR("spar"), + + @SerializedName("speedway") + SPEEDWAY("speedway"), + + @SerializedName("sun_company_inc") + SUN_COMPANY_INC("sun_company_inc"), + + @SerializedName("suncor_sunoco_canada") + SUNCOR_SUNOCO_CANADA("suncor_sunoco_canada"), + + @SerializedName("tempo") + TEMPO("tempo"), + + @SerializedName("tesco") + TESCO("tesco"), + + @SerializedName("tesoro_alaska") + TESORO_ALASKA("tesoro_alaska"), + + @SerializedName("texaco") + TEXACO("texaco"), + + @SerializedName("the_pantry_inc") + THE_PANTRY_INC("the_pantry_inc"), + + @SerializedName("thornton_oil") + THORNTON_OIL("thornton_oil"), + + @SerializedName("tosco") + TOSCO("tosco"), + + @SerializedName("total") + TOTAL("total"), + + @SerializedName("travel_centers_of_america") + TRAVEL_CENTERS_OF_AMERICA("travel_centers_of_america"), + + @SerializedName("uk") + UK("uk"), + + @SerializedName("ultramar_canada") + ULTRAMAR_CANADA("ultramar_canada"), + + @SerializedName("unbranded_or_unassigned") + UNBRANDED_OR_UNASSIGNED("unbranded_or_unassigned"), + + @SerializedName("unbranded_unassigned") + UNBRANDED_UNASSIGNED("unbranded_unassigned"), + + @SerializedName("union_76") + UNION_76("union_76"), + + @SerializedName("united_dairy_farmer") + UNITED_DAIRY_FARMER("united_dairy_farmer"), + + @SerializedName("united_refining_kwikfill") + UNITED_REFINING_KWIKFILL("united_refining_kwikfill"), + + @SerializedName("us_oil") + US_OIL("us_oil"), + + @SerializedName("usa_petroleum") + USA_PETROLEUM("usa_petroleum"), + + @SerializedName("valvoline") + VALVOLINE("valvoline"), + + @SerializedName("vg") + VG("vg"), + + @SerializedName("w_morrison") + W_MORRISON("w_morrison"), + + @SerializedName("warren_equities") + WARREN_EQUITIES("warren_equities"), + + @SerializedName("wawa") + WAWA("wawa"), + + @SerializedName("western_energetix") + WESTERN_ENERGETIX("western_energetix"), + + @SerializedName("wilco") + WILCO("wilco"), + + @SerializedName("zions") + ZIONS("zions"); @Getter(onMethod_ = {@Override}) private final String value; - Mode(String value) { + Brand(String value) { this.value = value; } } @@ -7452,7 +7858,15 @@ public enum Mode implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class Passenger { + public static class Station { + /** Additional contact information for the station. */ + @SerializedName("additional_contact_info") + String additionalContactInfo; + + /** The customer service phone number of the station. */ + @SerializedName("customer_service_phone_number") + String customerServicePhoneNumber; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -7463,15 +7877,37 @@ public static class Passenger { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** - * Required. Full name of the person or entity on the flight reservation. - */ - @SerializedName("name") - String name; + /** The partner ID code of the station. */ + @SerializedName("partner_id_code") + String partnerIdCode; - private Passenger(Map extraParams, String name) { + /** The phone number of the station. */ + @SerializedName("phone_number") + String phoneNumber; + + /** The physical location of the station. */ + @SerializedName("service_location") + ServiceLocation serviceLocation; + + /** The URL of the station. */ + @SerializedName("url") + String url; + + private Station( + String additionalContactInfo, + String customerServicePhoneNumber, + Map extraParams, + String partnerIdCode, + String phoneNumber, + ServiceLocation serviceLocation, + String url) { + this.additionalContactInfo = additionalContactInfo; + this.customerServicePhoneNumber = customerServicePhoneNumber; this.extraParams = extraParams; - this.name = name; + this.partnerIdCode = partnerIdCode; + this.phoneNumber = phoneNumber; + this.serviceLocation = serviceLocation; + this.url = url; } public static Builder builder() { @@ -7479,21 +7915,50 @@ public static Builder builder() { } public static class Builder { + private String additionalContactInfo; + + private String customerServicePhoneNumber; + private Map extraParams; - private String name; + private String partnerIdCode; + + private String phoneNumber; + + private ServiceLocation serviceLocation; + + private String url; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.Flight.Passenger build() { - return new PaymentIntentCaptureParams.PaymentDetails.Flight.Passenger( - this.extraParams, this.name); + public PaymentIntentCaptureParams.PaymentDetails.FleetData.Station build() { + return new PaymentIntentCaptureParams.PaymentDetails.FleetData.Station( + this.additionalContactInfo, + this.customerServicePhoneNumber, + this.extraParams, + this.partnerIdCode, + this.phoneNumber, + this.serviceLocation, + this.url); + } + + /** Additional contact information for the station. */ + public Builder setAdditionalContactInfo(String additionalContactInfo) { + this.additionalContactInfo = additionalContactInfo; + return this; + } + + /** The customer service phone number of the station. */ + public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight.Passenger#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FleetData.Station#extraParams} for the field + * documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -7506,8 +7971,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight.Passenger#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FleetData.Station#extraParams} for the field + * documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -7517,182 +7983,250 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Required. Full name of the person or entity on the flight reservation. - */ - public Builder setName(String name) { - this.name = name; + /** The partner ID code of the station. */ + public Builder setPartnerIdCode(String partnerIdCode) { + this.partnerIdCode = partnerIdCode; return this; } - } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Segment { - /** The flight segment amount. */ - @SerializedName("amount") - Long amount; + /** The phone number of the station. */ + public Builder setPhoneNumber(String phoneNumber) { + this.phoneNumber = phoneNumber; + return this; + } - /** - * The International Air Transport Association (IATA) airport code for the arrival airport. - */ - @SerializedName("arrival_airport") - String arrivalAirport; + /** The physical location of the station. */ + public Builder setServiceLocation( + PaymentIntentCaptureParams.PaymentDetails.FleetData.Station.ServiceLocation + serviceLocation) { + this.serviceLocation = serviceLocation; + return this; + } - /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ - @SerializedName("arrives_at") - Long arrivesAt; + /** The URL of the station. */ + public Builder setUrl(String url) { + this.url = url; + return this; + } + } - /** - * The International Air Transport Association (IATA) carrier code of the carrier operating - * the flight segment. - */ - @SerializedName("carrier") - String carrier; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ServiceLocation { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + String city; - /** - * Required. The departure time for the flight segment. Measured in seconds - * since the Unix epoch. - */ - @SerializedName("departs_at") - Long departsAt; + /** + * Two-letter country code (ISO + * 3166-1 alpha-2). + */ + @SerializedName("country") + String country; - /** - * The International Air Transport Association (IATA) airport code for the departure - * airport. - */ - @SerializedName("departure_airport") - String departureAirport; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** + * Required. Address line 1, such as the street, PO Box, or company name. + */ + @SerializedName("line1") + String line1; - /** The flight number associated with the segment. */ - @SerializedName("flight_number") - String flightNumber; + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; - /** The fare class for the segment. */ - @SerializedName("service_class") - ServiceClass serviceClass; + /** ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; - private Segment( - Long amount, - String arrivalAirport, - Long arrivesAt, - String carrier, - Long departsAt, - String departureAirport, - Map extraParams, - String flightNumber, - ServiceClass serviceClass) { - this.amount = amount; - this.arrivalAirport = arrivalAirport; - this.arrivesAt = arrivesAt; - this.carrier = carrier; - this.departsAt = departsAt; - this.departureAirport = departureAirport; - this.extraParams = extraParams; - this.flightNumber = flightNumber; - this.serviceClass = serviceClass; - } + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; - public static Builder builder() { - return new Builder(); - } + private ServiceLocation( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } - public static class Builder { - private Long amount; + public static Builder builder() { + return new Builder(); + } - private String arrivalAirport; + public static class Builder { + private String city; - private Long arrivesAt; + private String country; - private String carrier; + private Map extraParams; - private Long departsAt; + private String line1; - private String departureAirport; + private String line2; - private Map extraParams; + private String postalCode; - private String flightNumber; + private String state; - private ServiceClass serviceClass; + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.FleetData.Station.ServiceLocation + build() { + return new PaymentIntentCaptureParams.PaymentDetails.FleetData.Station + .ServiceLocation( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.Flight.Segment build() { - return new PaymentIntentCaptureParams.PaymentDetails.Flight.Segment( - this.amount, - this.arrivalAirport, - this.arrivesAt, - this.carrier, - this.departsAt, - this.departureAirport, - this.extraParams, - this.flightNumber, - this.serviceClass); - } + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } - /** The flight segment amount. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } - /** - * The International Air Transport Association (IATA) airport code for the arrival - * airport. - */ - public Builder setArrivalAirport(String arrivalAirport) { - this.arrivalAirport = arrivalAirport; - return this; - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FleetData.Station.ServiceLocation#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ - public Builder setArrivesAt(Long arrivesAt) { - this.arrivesAt = arrivesAt; - return this; - } + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FleetData.Station.ServiceLocation#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** - * The International Air Transport Association (IATA) carrier code of the carrier - * operating the flight segment. - */ - public Builder setCarrier(String carrier) { - this.carrier = carrier; - return this; - } + /** + * Required. Address line 1, such as the street, PO Box, or company + * name. + */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } - /** - * Required. The departure time for the flight segment. Measured in - * seconds since the Unix epoch. - */ - public Builder setDepartsAt(Long departsAt) { - this.departsAt = departsAt; - return this; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } + + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } + + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } } + } + } - /** - * The International Air Transport Association (IATA) airport code for the departure - * airport. - */ - public Builder setDepartureAirport(String departureAirport) { - this.departureAirport = departureAirport; - return this; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Vat { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** + * Required. Indicates the merchant's agreement for Invoice on Behalf (IOB) + * VAT processing. + */ + @SerializedName("iob_indicator") + IobIndicator iobIndicator; + + private Vat(Map extraParams, IobIndicator iobIndicator) { + this.extraParams = extraParams; + this.iobIndicator = iobIndicator; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private IobIndicator iobIndicator; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.FleetData.Vat build() { + return new PaymentIntentCaptureParams.PaymentDetails.FleetData.Vat( + this.extraParams, this.iobIndicator); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight.Segment#extraParams} + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.FleetData.Vat#extraParams} * for the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -7706,7 +8240,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight.Segment#extraParams} + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.FleetData.Vat#extraParams} * for the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -7717,37 +8251,32 @@ public Builder putAllExtraParam(Map map) { return this; } - /** The flight number associated with the segment. */ - public Builder setFlightNumber(String flightNumber) { - this.flightNumber = flightNumber; - return this; - } - - /** The fare class for the segment. */ - public Builder setServiceClass( - PaymentIntentCaptureParams.PaymentDetails.Flight.Segment.ServiceClass serviceClass) { - this.serviceClass = serviceClass; + /** + * Required. Indicates the merchant's agreement for Invoice on Behalf + * (IOB) VAT processing. + */ + public Builder setIobIndicator( + PaymentIntentCaptureParams.PaymentDetails.FleetData.Vat.IobIndicator iobIndicator) { + this.iobIndicator = iobIndicator; return this; } } - public enum ServiceClass implements ApiRequestParams.EnumParam { - @SerializedName("business") - BUSINESS("business"), - - @SerializedName("economy") - ECONOMY("economy"), + public enum IobIndicator implements ApiRequestParams.EnumParam { + @SerializedName("issuer_to_iob") + ISSUER_TO_IOB("issuer_to_iob"), - @SerializedName("first") - FIRST("first"), + @SerializedName("issuer_to_iob_and_incremental_certification") + ISSUER_TO_IOB_AND_INCREMENTAL_CERTIFICATION( + "issuer_to_iob_and_incremental_certification"), - @SerializedName("premium_economy") - PREMIUM_ECONOMY("premium_economy"); + @SerializedName("merchant_does_not_agree_to_iob") + MERCHANT_DOES_NOT_AGREE_TO_IOB("merchant_does_not_agree_to_iob"); @Getter(onMethod_ = {@Override}) private final String value; - ServiceClass(String value) { + IobIndicator(String value) { this.value = value; } } @@ -7756,22 +8285,28 @@ public enum ServiceClass implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class FlightData { - /** Affiliate details if applicable. */ + public static class Flight { + /** Affiliate details for this purchase. */ @SerializedName("affiliate") Affiliate affiliate; - /** Reservation reference. */ - @SerializedName("booking_number") - String bookingNumber; + /** + * The agency number (i.e. International Air Transport Association (IATA) agency number) of + * the travel agency that made the booking. + */ + @SerializedName("agency_number") + String agencyNumber; - /** Computerized reservation system used to make the reservation and purchase the ticket. */ - @SerializedName("computerized_reservation_system") - String computerizedReservationSystem; + /** + * The International Air Transport Association (IATA) carrier code of the carrier that issued + * the ticket. + */ + @SerializedName("carrier") + String carrier; - /** Ticket restrictions. */ - @SerializedName("endorsements_and_restrictions") - String endorsementsAndRestrictions; + /** Delivery details for this purchase. */ + @SerializedName("delivery") + Delivery delivery; /** * Map of extra parameters for custom features not available in this client library. The @@ -7782,53 +8317,41 @@ public static class FlightData { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** List of insurances. */ - @SerializedName("insurances") - List insurances; + /** The name of the person or entity on the reservation. */ + @SerializedName("passenger_name") + String passengerName; - /** List of passengers. */ + /** The details of the passengers in the travel reservation. */ @SerializedName("passengers") - List passengers; + List passengers; - /** Required. List of flight segments. */ + /** Required. The individual flight segments associated with the trip. */ @SerializedName("segments") - List segments; - - /** Electronic ticket indicator. */ - @SerializedName("ticket_electronically_issued_indicator") - Boolean ticketElectronicallyIssuedIndicator; - - /** Required. Total cost breakdown. */ - @SerializedName("total") - Total total; + List segments; - /** Type of flight transaction. */ - @SerializedName("transaction_type") - TransactionType transactionType; + /** The ticket number associated with the travel reservation. */ + @SerializedName("ticket_number") + String ticketNumber; - private FlightData( + private Flight( Affiliate affiliate, - String bookingNumber, - String computerizedReservationSystem, - String endorsementsAndRestrictions, + String agencyNumber, + String carrier, + Delivery delivery, Map extraParams, - List insurances, - List passengers, - List segments, - Boolean ticketElectronicallyIssuedIndicator, - Total total, - TransactionType transactionType) { + String passengerName, + List passengers, + List segments, + String ticketNumber) { this.affiliate = affiliate; - this.bookingNumber = bookingNumber; - this.computerizedReservationSystem = computerizedReservationSystem; - this.endorsementsAndRestrictions = endorsementsAndRestrictions; + this.agencyNumber = agencyNumber; + this.carrier = carrier; + this.delivery = delivery; this.extraParams = extraParams; - this.insurances = insurances; + this.passengerName = passengerName; this.passengers = passengers; this.segments = segments; - this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; - this.total = total; - this.transactionType = transactionType; + this.ticketNumber = ticketNumber; } public static Builder builder() { @@ -7838,71 +8361,72 @@ public static Builder builder() { public static class Builder { private Affiliate affiliate; - private String bookingNumber; + private String agencyNumber; - private String computerizedReservationSystem; + private String carrier; - private String endorsementsAndRestrictions; + private Delivery delivery; private Map extraParams; - private List insurances; - - private List passengers; - - private List segments; + private String passengerName; - private Boolean ticketElectronicallyIssuedIndicator; + private List passengers; - private Total total; + private List segments; - private TransactionType transactionType; + private String ticketNumber; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.FlightData build() { - return new PaymentIntentCaptureParams.PaymentDetails.FlightData( + public PaymentIntentCaptureParams.PaymentDetails.Flight build() { + return new PaymentIntentCaptureParams.PaymentDetails.Flight( this.affiliate, - this.bookingNumber, - this.computerizedReservationSystem, - this.endorsementsAndRestrictions, + this.agencyNumber, + this.carrier, + this.delivery, this.extraParams, - this.insurances, + this.passengerName, this.passengers, this.segments, - this.ticketElectronicallyIssuedIndicator, - this.total, - this.transactionType); + this.ticketNumber); } - /** Affiliate details if applicable. */ + /** Affiliate details for this purchase. */ public Builder setAffiliate( - PaymentIntentCaptureParams.PaymentDetails.FlightData.Affiliate affiliate) { + PaymentIntentCaptureParams.PaymentDetails.Flight.Affiliate affiliate) { this.affiliate = affiliate; return this; } - /** Reservation reference. */ - public Builder setBookingNumber(String bookingNumber) { - this.bookingNumber = bookingNumber; + /** + * The agency number (i.e. International Air Transport Association (IATA) agency number) of + * the travel agency that made the booking. + */ + public Builder setAgencyNumber(String agencyNumber) { + this.agencyNumber = agencyNumber; return this; } - /** Computerized reservation system used to make the reservation and purchase the ticket. */ - public Builder setComputerizedReservationSystem(String computerizedReservationSystem) { - this.computerizedReservationSystem = computerizedReservationSystem; + /** + * The International Air Transport Association (IATA) carrier code of the carrier that + * issued the ticket. + */ + public Builder setCarrier(String carrier) { + this.carrier = carrier; return this; } - /** Ticket restrictions. */ - public Builder setEndorsementsAndRestrictions(String endorsementsAndRestrictions) { - this.endorsementsAndRestrictions = endorsementsAndRestrictions; + /** Delivery details for this purchase. */ + public Builder setDelivery( + PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery delivery) { + this.delivery = delivery; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCaptureParams.PaymentDetails.FlightData#extraParams} for the + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight#extraParams} for the * field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -7916,7 +8440,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCaptureParams.PaymentDetails.FlightData#extraParams} for the + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight#extraParams} for the * field documentation. */ public Builder putAllExtraParam(Map map) { @@ -7927,44 +8451,19 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Add an element to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCaptureParams.PaymentDetails.FlightData#insurances} for the field - * documentation. - */ - public Builder addInsurance( - PaymentIntentCaptureParams.PaymentDetails.FlightData.Insurance element) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); - } - this.insurances.add(element); - return this; - } - - /** - * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCaptureParams.PaymentDetails.FlightData#insurances} for the field - * documentation. - */ - public Builder addAllInsurance( - List elements) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); - } - this.insurances.addAll(elements); + /** The name of the person or entity on the reservation. */ + public Builder setPassengerName(String passengerName) { + this.passengerName = passengerName; return this; } /** * Add an element to `passengers` list. A list is initialized for the first `add/addAll` * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCaptureParams.PaymentDetails.FlightData#passengers} for the field - * documentation. + * PaymentIntentCaptureParams.PaymentDetails.Flight#passengers} for the field documentation. */ public Builder addPassenger( - PaymentIntentCaptureParams.PaymentDetails.FlightData.Passenger element) { + PaymentIntentCaptureParams.PaymentDetails.Flight.Passenger element) { if (this.passengers == null) { this.passengers = new ArrayList<>(); } @@ -7975,11 +8474,10 @@ public Builder addPassenger( /** * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCaptureParams.PaymentDetails.FlightData#passengers} for the field - * documentation. + * PaymentIntentCaptureParams.PaymentDetails.Flight#passengers} for the field documentation. */ public Builder addAllPassenger( - List elements) { + List elements) { if (this.passengers == null) { this.passengers = new ArrayList<>(); } @@ -7990,11 +8488,10 @@ public Builder addAllPassenger( /** * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, * and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCaptureParams.PaymentDetails.FlightData#segments} for the field - * documentation. + * PaymentIntentCaptureParams.PaymentDetails.Flight#segments} for the field documentation. */ public Builder addSegment( - PaymentIntentCaptureParams.PaymentDetails.FlightData.Segment element) { + PaymentIntentCaptureParams.PaymentDetails.Flight.Segment element) { if (this.segments == null) { this.segments = new ArrayList<>(); } @@ -8005,11 +8502,10 @@ public Builder addSegment( /** * Add all elements to `segments` list. A list is initialized for the first `add/addAll` * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCaptureParams.PaymentDetails.FlightData#segments} for the field - * documentation. + * PaymentIntentCaptureParams.PaymentDetails.Flight#segments} for the field documentation. */ public Builder addAllSegment( - List elements) { + List elements) { if (this.segments == null) { this.segments = new ArrayList<>(); } @@ -8017,23 +8513,9 @@ public Builder addAllSegment( return this; } - /** Electronic ticket indicator. */ - public Builder setTicketElectronicallyIssuedIndicator( - Boolean ticketElectronicallyIssuedIndicator) { - this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; - return this; - } - - /** Required. Total cost breakdown. */ - public Builder setTotal(PaymentIntentCaptureParams.PaymentDetails.FlightData.Total total) { - this.total = total; - return this; - } - - /** Type of flight transaction. */ - public Builder setTransactionType( - PaymentIntentCaptureParams.PaymentDetails.FlightData.TransactionType transactionType) { - this.transactionType = transactionType; + /** The ticket number associated with the travel reservation. */ + public Builder setTicketNumber(String ticketNumber) { + this.ticketNumber = ticketNumber; return this; } } @@ -8041,10 +8523,6 @@ public Builder setTransactionType( @Getter @EqualsAndHashCode(callSuper = false) public static class Affiliate { - /** Affiliate partner code. */ - @SerializedName("code") - String code; - /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -8055,23 +8533,13 @@ public static class Affiliate { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Name of affiliate partner. */ + /** Required. The name of the affiliate that originated the purchase. */ @SerializedName("name") String name; - /** Code provided by the company to a travel agent authorizing ticket issuance. */ - @SerializedName("travel_authorization_code") - String travelAuthorizationCode; - - private Affiliate( - String code, - Map extraParams, - String name, - String travelAuthorizationCode) { - this.code = code; + private Affiliate(Map extraParams, String name) { this.extraParams = extraParams; this.name = name; - this.travelAuthorizationCode = travelAuthorizationCode; } public static Builder builder() { @@ -8079,32 +8547,21 @@ public static Builder builder() { } public static class Builder { - private String code; - private Map extraParams; private String name; - private String travelAuthorizationCode; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.FlightData.Affiliate build() { - return new PaymentIntentCaptureParams.PaymentDetails.FlightData.Affiliate( - this.code, this.extraParams, this.name, this.travelAuthorizationCode); - } - - /** Affiliate partner code. */ - public Builder setCode(String code) { - this.code = code; - return this; + public PaymentIntentCaptureParams.PaymentDetails.Flight.Affiliate build() { + return new PaymentIntentCaptureParams.PaymentDetails.Flight.Affiliate( + this.extraParams, this.name); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.FlightData.Affiliate#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight.Affiliate#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -8117,9 +8574,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.FlightData.Affiliate#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight.Affiliate#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -8129,31 +8585,17 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Name of affiliate partner. */ + /** Required. The name of the affiliate that originated the purchase. */ public Builder setName(String name) { this.name = name; return this; } - - /** Code provided by the company to a travel agent authorizing ticket issuance. */ - public Builder setTravelAuthorizationCode(String travelAuthorizationCode) { - this.travelAuthorizationCode = travelAuthorizationCode; - return this; - } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Insurance { - /** Required. Insurance cost. */ - @SerializedName("amount") - Long amount; - - /** Insurance currency. */ - @SerializedName("currency") - String currency; - + public static class Delivery { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -8164,25 +8606,18 @@ public static class Insurance { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Insurance company name. */ - @SerializedName("insurance_company_name") - String insuranceCompanyName; + /** The delivery method for the payment. */ + @SerializedName("mode") + Mode mode; - /** Required. Type of insurance. */ - @SerializedName("insurance_type") - InsuranceType insuranceType; + /** Details of the recipient. */ + @SerializedName("recipient") + Recipient recipient; - private Insurance( - Long amount, - String currency, - Map extraParams, - String insuranceCompanyName, - InsuranceType insuranceType) { - this.amount = amount; - this.currency = currency; + private Delivery(Map extraParams, Mode mode, Recipient recipient) { this.extraParams = extraParams; - this.insuranceCompanyName = insuranceCompanyName; - this.insuranceType = insuranceType; + this.mode = mode; + this.recipient = recipient; } public static Builder builder() { @@ -8190,44 +8625,23 @@ public static Builder builder() { } public static class Builder { - private Long amount; - - private String currency; - private Map extraParams; - private String insuranceCompanyName; + private Mode mode; - private InsuranceType insuranceType; + private Recipient recipient; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.FlightData.Insurance build() { - return new PaymentIntentCaptureParams.PaymentDetails.FlightData.Insurance( - this.amount, - this.currency, - this.extraParams, - this.insuranceCompanyName, - this.insuranceType); - } - - /** Required. Insurance cost. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } - - /** Insurance currency. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; + public PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery build() { + return new PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery( + this.extraParams, this.mode, this.recipient); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.FlightData.Insurance#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -8240,9 +8654,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.FlightData.Insurance#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -8252,41 +8665,140 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Insurance company name. */ - public Builder setInsuranceCompanyName(String insuranceCompanyName) { - this.insuranceCompanyName = insuranceCompanyName; + /** The delivery method for the payment. */ + public Builder setMode( + PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery.Mode mode) { + this.mode = mode; return this; } - /** Required. Type of insurance. */ - public Builder setInsuranceType( - PaymentIntentCaptureParams.PaymentDetails.FlightData.Insurance.InsuranceType - insuranceType) { - this.insuranceType = insuranceType; + /** Details of the recipient. */ + public Builder setRecipient( + PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery.Recipient recipient) { + this.recipient = recipient; return this; } } - public enum InsuranceType implements ApiRequestParams.EnumParam { - @SerializedName("baggage") - BAGGAGE("baggage"), + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Recipient { + /** The email of the recipient the ticket is delivered to. */ + @SerializedName("email") + String email; - @SerializedName("bankruptcy") - BANKRUPTCY("bankruptcy"), + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - @SerializedName("cancelation") - CANCELATION("cancelation"), + /** The name of the recipient the ticket is delivered to. */ + @SerializedName("name") + String name; - @SerializedName("emergency") - EMERGENCY("emergency"), + /** The phone number of the recipient the ticket is delivered to. */ + @SerializedName("phone") + String phone; - @SerializedName("medical") - MEDICAL("medical"); + private Recipient( + String email, Map extraParams, String name, String phone) { + this.email = email; + this.extraParams = extraParams; + this.name = name; + this.phone = phone; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String email; + + private Map extraParams; + + private String name; + + private String phone; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery.Recipient build() { + return new PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery.Recipient( + this.email, this.extraParams, this.name, this.phone); + } + + /** The email of the recipient the ticket is delivered to. */ + public Builder setEmail(String email) { + this.email = email; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The name of the recipient the ticket is delivered to. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** The phone number of the recipient the ticket is delivered to. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } + } + } + + public enum Mode implements ApiRequestParams.EnumParam { + @SerializedName("email") + EMAIL("email"), + + @SerializedName("phone") + PHONE("phone"), + + @SerializedName("pickup") + PICKUP("pickup"), + + @SerializedName("post") + POST("post"); @Getter(onMethod_ = {@Override}) private final String value; - InsuranceType(String value) { + Mode(String value) { this.value = value; } } @@ -8305,7 +8817,9 @@ public static class Passenger { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Required. Passenger's full name. */ + /** + * Required. Full name of the person or entity on the flight reservation. + */ @SerializedName("name") String name; @@ -8324,17 +8838,16 @@ public static class Builder { private String name; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.FlightData.Passenger build() { - return new PaymentIntentCaptureParams.PaymentDetails.FlightData.Passenger( + public PaymentIntentCaptureParams.PaymentDetails.Flight.Passenger build() { + return new PaymentIntentCaptureParams.PaymentDetails.Flight.Passenger( this.extraParams, this.name); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.FlightData.Passenger#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight.Passenger#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -8347,9 +8860,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.FlightData.Passenger#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight.Passenger#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -8359,7 +8871,9 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Required. Passenger's full name. */ + /** + * Required. Full name of the person or entity on the flight reservation. + */ public Builder setName(String name) { this.name = name; return this; @@ -8370,33 +8884,40 @@ public Builder setName(String name) { @Getter @EqualsAndHashCode(callSuper = false) public static class Segment { - /** Segment fare amount. */ + /** The flight segment amount. */ @SerializedName("amount") Long amount; - /** Required. Arrival details. */ - @SerializedName("arrival") - Arrival arrival; - - /** Required. Airline carrier code. */ - @SerializedName("carrier_code") - String carrierCode; + /** + * The International Air Transport Association (IATA) airport code for the arrival airport. + */ + @SerializedName("arrival_airport") + String arrivalAirport; - /** Carrier name. */ - @SerializedName("carrier_name") - String carrierName; + /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ + @SerializedName("arrives_at") + Long arrivesAt; - /** Segment currency. */ - @SerializedName("currency") - String currency; + /** + * The International Air Transport Association (IATA) carrier code of the carrier operating + * the flight segment. + */ + @SerializedName("carrier") + String carrier; - /** Required. Departure details. */ - @SerializedName("departure") - Departure departure; + /** + * Required. The departure time for the flight segment. Measured in seconds + * since the Unix epoch. + */ + @SerializedName("departs_at") + Long departsAt; - /** Exchange ticket number. */ - @SerializedName("exchange_ticket_number") - String exchangeTicketNumber; + /** + * The International Air Transport Association (IATA) airport code for the departure + * airport. + */ + @SerializedName("departure_airport") + String departureAirport; /** * Map of extra parameters for custom features not available in this client library. The @@ -8408,71 +8929,33 @@ public static class Segment { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Fare basis code. */ - @SerializedName("fare_basis_code") - String fareBasisCode; - - /** Additional fees. */ - @SerializedName("fees") - Long fees; - - /** Flight number. */ + /** The flight number associated with the segment. */ @SerializedName("flight_number") String flightNumber; - /** Stopover indicator. */ - @SerializedName("is_stop_over_indicator") - Boolean isStopOverIndicator; - - /** Refundable ticket indicator. */ - @SerializedName("refundable") - Boolean refundable; - - /** Required. Class of service. */ + /** The fare class for the segment. */ @SerializedName("service_class") ServiceClass serviceClass; - /** Tax amount for segment. */ - @SerializedName("tax_amount") - Long taxAmount; - - /** Ticket number. */ - @SerializedName("ticket_number") - String ticketNumber; - private Segment( Long amount, - Arrival arrival, - String carrierCode, - String carrierName, - String currency, - Departure departure, - String exchangeTicketNumber, + String arrivalAirport, + Long arrivesAt, + String carrier, + Long departsAt, + String departureAirport, Map extraParams, - String fareBasisCode, - Long fees, String flightNumber, - Boolean isStopOverIndicator, - Boolean refundable, - ServiceClass serviceClass, - Long taxAmount, - String ticketNumber) { + ServiceClass serviceClass) { this.amount = amount; - this.arrival = arrival; - this.carrierCode = carrierCode; - this.carrierName = carrierName; - this.currency = currency; - this.departure = departure; - this.exchangeTicketNumber = exchangeTicketNumber; + this.arrivalAirport = arrivalAirport; + this.arrivesAt = arrivesAt; + this.carrier = carrier; + this.departsAt = departsAt; + this.departureAirport = departureAirport; this.extraParams = extraParams; - this.fareBasisCode = fareBasisCode; - this.fees = fees; this.flightNumber = flightNumber; - this.isStopOverIndicator = isStopOverIndicator; - this.refundable = refundable; this.serviceClass = serviceClass; - this.taxAmount = taxAmount; - this.ticketNumber = ticketNumber; } public static Builder builder() { @@ -8482,107 +8965,89 @@ public static Builder builder() { public static class Builder { private Long amount; - private Arrival arrival; - - private String carrierCode; + private String arrivalAirport; - private String carrierName; + private Long arrivesAt; - private String currency; + private String carrier; - private Departure departure; + private Long departsAt; - private String exchangeTicketNumber; + private String departureAirport; private Map extraParams; - private String fareBasisCode; - - private Long fees; - private String flightNumber; - private Boolean isStopOverIndicator; - - private Boolean refundable; - private ServiceClass serviceClass; - private Long taxAmount; - - private String ticketNumber; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.FlightData.Segment build() { - return new PaymentIntentCaptureParams.PaymentDetails.FlightData.Segment( + public PaymentIntentCaptureParams.PaymentDetails.Flight.Segment build() { + return new PaymentIntentCaptureParams.PaymentDetails.Flight.Segment( this.amount, - this.arrival, - this.carrierCode, - this.carrierName, - this.currency, - this.departure, - this.exchangeTicketNumber, + this.arrivalAirport, + this.arrivesAt, + this.carrier, + this.departsAt, + this.departureAirport, this.extraParams, - this.fareBasisCode, - this.fees, this.flightNumber, - this.isStopOverIndicator, - this.refundable, - this.serviceClass, - this.taxAmount, - this.ticketNumber); + this.serviceClass); } - /** Segment fare amount. */ + /** The flight segment amount. */ public Builder setAmount(Long amount) { this.amount = amount; return this; } - /** Required. Arrival details. */ - public Builder setArrival( - PaymentIntentCaptureParams.PaymentDetails.FlightData.Segment.Arrival arrival) { - this.arrival = arrival; - return this; - } - - /** Required. Airline carrier code. */ - public Builder setCarrierCode(String carrierCode) { - this.carrierCode = carrierCode; + /** + * The International Air Transport Association (IATA) airport code for the arrival + * airport. + */ + public Builder setArrivalAirport(String arrivalAirport) { + this.arrivalAirport = arrivalAirport; return this; } - /** Carrier name. */ - public Builder setCarrierName(String carrierName) { - this.carrierName = carrierName; + /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ + public Builder setArrivesAt(Long arrivesAt) { + this.arrivesAt = arrivesAt; return this; } - /** Segment currency. */ - public Builder setCurrency(String currency) { - this.currency = currency; + /** + * The International Air Transport Association (IATA) carrier code of the carrier + * operating the flight segment. + */ + public Builder setCarrier(String carrier) { + this.carrier = carrier; return this; } - /** Required. Departure details. */ - public Builder setDeparture( - PaymentIntentCaptureParams.PaymentDetails.FlightData.Segment.Departure departure) { - this.departure = departure; + /** + * Required. The departure time for the flight segment. Measured in + * seconds since the Unix epoch. + */ + public Builder setDepartsAt(Long departsAt) { + this.departsAt = departsAt; return this; } - /** Exchange ticket number. */ - public Builder setExchangeTicketNumber(String exchangeTicketNumber) { - this.exchangeTicketNumber = exchangeTicketNumber; + /** + * The International Air Transport Association (IATA) airport code for the departure + * airport. + */ + public Builder setDepartureAirport(String departureAirport) { + this.departureAirport = departureAirport; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.FlightData.Segment#extraParams} for the field - * documentation. + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight.Segment#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -8595,9 +9060,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.FlightData.Segment#extraParams} for the field - * documentation. + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.Flight.Segment#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -8607,49 +9071,939 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Fare basis code. */ - public Builder setFareBasisCode(String fareBasisCode) { - this.fareBasisCode = fareBasisCode; - return this; - } - - /** Additional fees. */ - public Builder setFees(Long fees) { - this.fees = fees; - return this; - } - - /** Flight number. */ + /** The flight number associated with the segment. */ public Builder setFlightNumber(String flightNumber) { this.flightNumber = flightNumber; return this; } - /** Stopover indicator. */ - public Builder setIsStopOverIndicator(Boolean isStopOverIndicator) { - this.isStopOverIndicator = isStopOverIndicator; - return this; - } - - /** Refundable ticket indicator. */ - public Builder setRefundable(Boolean refundable) { - this.refundable = refundable; - return this; - } - - /** Required. Class of service. */ + /** The fare class for the segment. */ public Builder setServiceClass( - PaymentIntentCaptureParams.PaymentDetails.FlightData.Segment.ServiceClass - serviceClass) { + PaymentIntentCaptureParams.PaymentDetails.Flight.Segment.ServiceClass serviceClass) { this.serviceClass = serviceClass; return this; } + } - /** Tax amount for segment. */ - public Builder setTaxAmount(Long taxAmount) { - this.taxAmount = taxAmount; - return this; - } + public enum ServiceClass implements ApiRequestParams.EnumParam { + @SerializedName("business") + BUSINESS("business"), + + @SerializedName("economy") + ECONOMY("economy"), + + @SerializedName("first") + FIRST("first"), + + @SerializedName("premium_economy") + PREMIUM_ECONOMY("premium_economy"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ServiceClass(String value) { + this.value = value; + } + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class FlightData { + /** Affiliate details if applicable. */ + @SerializedName("affiliate") + Affiliate affiliate; + + /** Reservation reference. */ + @SerializedName("booking_number") + String bookingNumber; + + /** Computerized reservation system used to make the reservation and purchase the ticket. */ + @SerializedName("computerized_reservation_system") + String computerizedReservationSystem; + + /** Ticket restrictions. */ + @SerializedName("endorsements_and_restrictions") + String endorsementsAndRestrictions; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** List of insurances. */ + @SerializedName("insurances") + List insurances; + + /** List of passengers. */ + @SerializedName("passengers") + List passengers; + + /** Required. List of flight segments. */ + @SerializedName("segments") + List segments; + + /** Electronic ticket indicator. */ + @SerializedName("ticket_electronically_issued_indicator") + Boolean ticketElectronicallyIssuedIndicator; + + /** Required. Total cost breakdown. */ + @SerializedName("total") + Total total; + + /** Type of flight transaction. */ + @SerializedName("transaction_type") + TransactionType transactionType; + + private FlightData( + Affiliate affiliate, + String bookingNumber, + String computerizedReservationSystem, + String endorsementsAndRestrictions, + Map extraParams, + List insurances, + List passengers, + List segments, + Boolean ticketElectronicallyIssuedIndicator, + Total total, + TransactionType transactionType) { + this.affiliate = affiliate; + this.bookingNumber = bookingNumber; + this.computerizedReservationSystem = computerizedReservationSystem; + this.endorsementsAndRestrictions = endorsementsAndRestrictions; + this.extraParams = extraParams; + this.insurances = insurances; + this.passengers = passengers; + this.segments = segments; + this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; + this.total = total; + this.transactionType = transactionType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Affiliate affiliate; + + private String bookingNumber; + + private String computerizedReservationSystem; + + private String endorsementsAndRestrictions; + + private Map extraParams; + + private List insurances; + + private List passengers; + + private List segments; + + private Boolean ticketElectronicallyIssuedIndicator; + + private Total total; + + private TransactionType transactionType; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.FlightData build() { + return new PaymentIntentCaptureParams.PaymentDetails.FlightData( + this.affiliate, + this.bookingNumber, + this.computerizedReservationSystem, + this.endorsementsAndRestrictions, + this.extraParams, + this.insurances, + this.passengers, + this.segments, + this.ticketElectronicallyIssuedIndicator, + this.total, + this.transactionType); + } + + /** Affiliate details if applicable. */ + public Builder setAffiliate( + PaymentIntentCaptureParams.PaymentDetails.FlightData.Affiliate affiliate) { + this.affiliate = affiliate; + return this; + } + + /** Reservation reference. */ + public Builder setBookingNumber(String bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } + + /** Computerized reservation system used to make the reservation and purchase the ticket. */ + public Builder setComputerizedReservationSystem(String computerizedReservationSystem) { + this.computerizedReservationSystem = computerizedReservationSystem; + return this; + } + + /** Ticket restrictions. */ + public Builder setEndorsementsAndRestrictions(String endorsementsAndRestrictions) { + this.endorsementsAndRestrictions = endorsementsAndRestrictions; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.FlightData#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.FlightData#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Add an element to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FlightData#insurances} for the field + * documentation. + */ + public Builder addInsurance( + PaymentIntentCaptureParams.PaymentDetails.FlightData.Insurance element) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); + } + this.insurances.add(element); + return this; + } + + /** + * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FlightData#insurances} for the field + * documentation. + */ + public Builder addAllInsurance( + List elements) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); + } + this.insurances.addAll(elements); + return this; + } + + /** + * Add an element to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FlightData#passengers} for the field + * documentation. + */ + public Builder addPassenger( + PaymentIntentCaptureParams.PaymentDetails.FlightData.Passenger element) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.add(element); + return this; + } + + /** + * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FlightData#passengers} for the field + * documentation. + */ + public Builder addAllPassenger( + List elements) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.addAll(elements); + return this; + } + + /** + * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FlightData#segments} for the field + * documentation. + */ + public Builder addSegment( + PaymentIntentCaptureParams.PaymentDetails.FlightData.Segment element) { + if (this.segments == null) { + this.segments = new ArrayList<>(); + } + this.segments.add(element); + return this; + } + + /** + * Add all elements to `segments` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FlightData#segments} for the field + * documentation. + */ + public Builder addAllSegment( + List elements) { + if (this.segments == null) { + this.segments = new ArrayList<>(); + } + this.segments.addAll(elements); + return this; + } + + /** Electronic ticket indicator. */ + public Builder setTicketElectronicallyIssuedIndicator( + Boolean ticketElectronicallyIssuedIndicator) { + this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; + return this; + } + + /** Required. Total cost breakdown. */ + public Builder setTotal(PaymentIntentCaptureParams.PaymentDetails.FlightData.Total total) { + this.total = total; + return this; + } + + /** Type of flight transaction. */ + public Builder setTransactionType( + PaymentIntentCaptureParams.PaymentDetails.FlightData.TransactionType transactionType) { + this.transactionType = transactionType; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Affiliate { + /** Affiliate partner code. */ + @SerializedName("code") + String code; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Name of affiliate partner. */ + @SerializedName("name") + String name; + + /** Code provided by the company to a travel agent authorizing ticket issuance. */ + @SerializedName("travel_authorization_code") + String travelAuthorizationCode; + + private Affiliate( + String code, + Map extraParams, + String name, + String travelAuthorizationCode) { + this.code = code; + this.extraParams = extraParams; + this.name = name; + this.travelAuthorizationCode = travelAuthorizationCode; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String code; + + private Map extraParams; + + private String name; + + private String travelAuthorizationCode; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.FlightData.Affiliate build() { + return new PaymentIntentCaptureParams.PaymentDetails.FlightData.Affiliate( + this.code, this.extraParams, this.name, this.travelAuthorizationCode); + } + + /** Affiliate partner code. */ + public Builder setCode(String code) { + this.code = code; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FlightData.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FlightData.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Name of affiliate partner. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** Code provided by the company to a travel agent authorizing ticket issuance. */ + public Builder setTravelAuthorizationCode(String travelAuthorizationCode) { + this.travelAuthorizationCode = travelAuthorizationCode; + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Insurance { + /** Required. Insurance cost. */ + @SerializedName("amount") + Long amount; + + /** Insurance currency. */ + @SerializedName("currency") + String currency; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Insurance company name. */ + @SerializedName("insurance_company_name") + String insuranceCompanyName; + + /** Required. Type of insurance. */ + @SerializedName("insurance_type") + InsuranceType insuranceType; + + private Insurance( + Long amount, + String currency, + Map extraParams, + String insuranceCompanyName, + InsuranceType insuranceType) { + this.amount = amount; + this.currency = currency; + this.extraParams = extraParams; + this.insuranceCompanyName = insuranceCompanyName; + this.insuranceType = insuranceType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private String currency; + + private Map extraParams; + + private String insuranceCompanyName; + + private InsuranceType insuranceType; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.FlightData.Insurance build() { + return new PaymentIntentCaptureParams.PaymentDetails.FlightData.Insurance( + this.amount, + this.currency, + this.extraParams, + this.insuranceCompanyName, + this.insuranceType); + } + + /** Required. Insurance cost. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Insurance currency. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FlightData.Insurance#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FlightData.Insurance#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Insurance company name. */ + public Builder setInsuranceCompanyName(String insuranceCompanyName) { + this.insuranceCompanyName = insuranceCompanyName; + return this; + } + + /** Required. Type of insurance. */ + public Builder setInsuranceType( + PaymentIntentCaptureParams.PaymentDetails.FlightData.Insurance.InsuranceType + insuranceType) { + this.insuranceType = insuranceType; + return this; + } + } + + public enum InsuranceType implements ApiRequestParams.EnumParam { + @SerializedName("baggage") + BAGGAGE("baggage"), + + @SerializedName("bankruptcy") + BANKRUPTCY("bankruptcy"), + + @SerializedName("cancelation") + CANCELATION("cancelation"), + + @SerializedName("emergency") + EMERGENCY("emergency"), + + @SerializedName("medical") + MEDICAL("medical"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + InsuranceType(String value) { + this.value = value; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Passenger { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Required. Passenger's full name. */ + @SerializedName("name") + String name; + + private Passenger(Map extraParams, String name) { + this.extraParams = extraParams; + this.name = name; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String name; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.FlightData.Passenger build() { + return new PaymentIntentCaptureParams.PaymentDetails.FlightData.Passenger( + this.extraParams, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FlightData.Passenger#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FlightData.Passenger#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Required. Passenger's full name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Segment { + /** Segment fare amount. */ + @SerializedName("amount") + Long amount; + + /** Required. Arrival details. */ + @SerializedName("arrival") + Arrival arrival; + + /** Required. Airline carrier code. */ + @SerializedName("carrier_code") + String carrierCode; + + /** Carrier name. */ + @SerializedName("carrier_name") + String carrierName; + + /** Segment currency. */ + @SerializedName("currency") + String currency; + + /** Required. Departure details. */ + @SerializedName("departure") + Departure departure; + + /** Exchange ticket number. */ + @SerializedName("exchange_ticket_number") + String exchangeTicketNumber; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Fare basis code. */ + @SerializedName("fare_basis_code") + String fareBasisCode; + + /** Additional fees. */ + @SerializedName("fees") + Long fees; + + /** Flight number. */ + @SerializedName("flight_number") + String flightNumber; + + /** Stopover indicator. */ + @SerializedName("is_stop_over_indicator") + Boolean isStopOverIndicator; + + /** Refundable ticket indicator. */ + @SerializedName("refundable") + Boolean refundable; + + /** Required. Class of service. */ + @SerializedName("service_class") + ServiceClass serviceClass; + + /** Tax amount for segment. */ + @SerializedName("tax_amount") + Long taxAmount; + + /** Ticket number. */ + @SerializedName("ticket_number") + String ticketNumber; + + private Segment( + Long amount, + Arrival arrival, + String carrierCode, + String carrierName, + String currency, + Departure departure, + String exchangeTicketNumber, + Map extraParams, + String fareBasisCode, + Long fees, + String flightNumber, + Boolean isStopOverIndicator, + Boolean refundable, + ServiceClass serviceClass, + Long taxAmount, + String ticketNumber) { + this.amount = amount; + this.arrival = arrival; + this.carrierCode = carrierCode; + this.carrierName = carrierName; + this.currency = currency; + this.departure = departure; + this.exchangeTicketNumber = exchangeTicketNumber; + this.extraParams = extraParams; + this.fareBasisCode = fareBasisCode; + this.fees = fees; + this.flightNumber = flightNumber; + this.isStopOverIndicator = isStopOverIndicator; + this.refundable = refundable; + this.serviceClass = serviceClass; + this.taxAmount = taxAmount; + this.ticketNumber = ticketNumber; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private Arrival arrival; + + private String carrierCode; + + private String carrierName; + + private String currency; + + private Departure departure; + + private String exchangeTicketNumber; + + private Map extraParams; + + private String fareBasisCode; + + private Long fees; + + private String flightNumber; + + private Boolean isStopOverIndicator; + + private Boolean refundable; + + private ServiceClass serviceClass; + + private Long taxAmount; + + private String ticketNumber; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.FlightData.Segment build() { + return new PaymentIntentCaptureParams.PaymentDetails.FlightData.Segment( + this.amount, + this.arrival, + this.carrierCode, + this.carrierName, + this.currency, + this.departure, + this.exchangeTicketNumber, + this.extraParams, + this.fareBasisCode, + this.fees, + this.flightNumber, + this.isStopOverIndicator, + this.refundable, + this.serviceClass, + this.taxAmount, + this.ticketNumber); + } + + /** Segment fare amount. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Required. Arrival details. */ + public Builder setArrival( + PaymentIntentCaptureParams.PaymentDetails.FlightData.Segment.Arrival arrival) { + this.arrival = arrival; + return this; + } + + /** Required. Airline carrier code. */ + public Builder setCarrierCode(String carrierCode) { + this.carrierCode = carrierCode; + return this; + } + + /** Carrier name. */ + public Builder setCarrierName(String carrierName) { + this.carrierName = carrierName; + return this; + } + + /** Segment currency. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; + } + + /** Required. Departure details. */ + public Builder setDeparture( + PaymentIntentCaptureParams.PaymentDetails.FlightData.Segment.Departure departure) { + this.departure = departure; + return this; + } + + /** Exchange ticket number. */ + public Builder setExchangeTicketNumber(String exchangeTicketNumber) { + this.exchangeTicketNumber = exchangeTicketNumber; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FlightData.Segment#extraParams} for the field + * documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.FlightData.Segment#extraParams} for the field + * documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Fare basis code. */ + public Builder setFareBasisCode(String fareBasisCode) { + this.fareBasisCode = fareBasisCode; + return this; + } + + /** Additional fees. */ + public Builder setFees(Long fees) { + this.fees = fees; + return this; + } + + /** Flight number. */ + public Builder setFlightNumber(String flightNumber) { + this.flightNumber = flightNumber; + return this; + } + + /** Stopover indicator. */ + public Builder setIsStopOverIndicator(Boolean isStopOverIndicator) { + this.isStopOverIndicator = isStopOverIndicator; + return this; + } + + /** Refundable ticket indicator. */ + public Builder setRefundable(Boolean refundable) { + this.refundable = refundable; + return this; + } + + /** Required. Class of service. */ + public Builder setServiceClass( + PaymentIntentCaptureParams.PaymentDetails.FlightData.Segment.ServiceClass + serviceClass) { + this.serviceClass = serviceClass; + return this; + } + + /** Tax amount for segment. */ + public Builder setTaxAmount(Long taxAmount) { + this.taxAmount = taxAmount; + return this; + } /** Ticket number. */ public Builder setTicketNumber(String ticketNumber) { @@ -11110,23 +12464,251 @@ public static class Builder { private String name; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Affiliate build() { - return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Affiliate( - this.code, this.extraParams, this.name); + public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Affiliate build() { + return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Affiliate( + this.code, this.extraParams, this.name); + } + + /** Affiliate partner code. */ + public Builder setCode(String code) { + this.code = code; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Affiliate partner name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Guest { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Required. Guest's full name. */ + @SerializedName("name") + String name; + + private Guest(Map extraParams, String name) { + this.extraParams = extraParams; + this.name = name; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String name; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Guest build() { + return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Guest( + this.extraParams, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Guest#extraParams} for the field + * documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Guest#extraParams} for the field + * documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Required. Guest's full name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Host { + /** Address of the host. */ + @SerializedName("address") + Address address; + + /** Host's country of domicile. */ + @SerializedName("country_of_domicile") + String countryOfDomicile; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Reference number for the host. */ + @SerializedName("host_reference") + String hostReference; + + /** Type of host. */ + @SerializedName("host_type") + HostType hostType; + + /** Name of the lodging property or host. */ + @SerializedName("name") + String name; + + /** Total number of reservations for the host. */ + @SerializedName("number_of_reservations") + Long numberOfReservations; + + /** Property phone number. */ + @SerializedName("property_phone_number") + String propertyPhoneNumber; + + /** Host's registration date. */ + @SerializedName("registered_at") + Long registeredAt; + + private Host( + Address address, + String countryOfDomicile, + Map extraParams, + String hostReference, + HostType hostType, + String name, + Long numberOfReservations, + String propertyPhoneNumber, + Long registeredAt) { + this.address = address; + this.countryOfDomicile = countryOfDomicile; + this.extraParams = extraParams; + this.hostReference = hostReference; + this.hostType = hostType; + this.name = name; + this.numberOfReservations = numberOfReservations; + this.propertyPhoneNumber = propertyPhoneNumber; + this.registeredAt = registeredAt; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Address address; + + private String countryOfDomicile; + + private Map extraParams; + + private String hostReference; + + private HostType hostType; + + private String name; + + private Long numberOfReservations; + + private String propertyPhoneNumber; + + private Long registeredAt; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host build() { + return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host( + this.address, + this.countryOfDomicile, + this.extraParams, + this.hostReference, + this.hostType, + this.name, + this.numberOfReservations, + this.propertyPhoneNumber, + this.registeredAt); } - /** Affiliate partner code. */ - public Builder setCode(String code) { - this.code = code; + /** Address of the host. */ + public Builder setAddress( + PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host.Address address) { + this.address = address; + return this; + } + + /** Host's country of domicile. */ + public Builder setCountryOfDomicile(String countryOfDomicile) { + this.countryOfDomicile = countryOfDomicile; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Affiliate#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -11139,9 +12721,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Affiliate#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -11151,17 +12732,247 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Affiliate partner name. */ + /** Reference number for the host. */ + public Builder setHostReference(String hostReference) { + this.hostReference = hostReference; + return this; + } + + /** Type of host. */ + public Builder setHostType( + PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host.HostType hostType) { + this.hostType = hostType; + return this; + } + + /** Name of the lodging property or host. */ public Builder setName(String name) { this.name = name; return this; } + + /** Total number of reservations for the host. */ + public Builder setNumberOfReservations(Long numberOfReservations) { + this.numberOfReservations = numberOfReservations; + return this; + } + + /** Property phone number. */ + public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { + this.propertyPhoneNumber = propertyPhoneNumber; + return this; + } + + /** Host's registration date. */ + public Builder setRegisteredAt(Long registeredAt) { + this.registeredAt = registeredAt; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Address { + /** Required. City, district, suburb, town, or village. */ + @SerializedName("city") + String city; + + /** + * Required. Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + String country; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** + * Required. Address line 1, such as the street, PO Box, or company name. + */ + @SerializedName("line1") + String line1; + + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; + + /** Required. ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; + + private Address( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String city; + + private String country; + + private Map extraParams; + + private String line1; + + private String line2; + + private String postalCode; + + private String state; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host.Address build() { + return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } + + /** Required. City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** + * Required. Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host.Address#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host.Address#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. Address line 1, such as the street, PO Box, or company + * name. + */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } + + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } + + /** Required. ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } + + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + } + } + + public enum HostType implements ApiRequestParams.EnumParam { + @SerializedName("hostel") + HOSTEL("hostel"), + + @SerializedName("hotel") + HOTEL("hotel"), + + @SerializedName("owner") + OWNER("owner"), + + @SerializedName("rental_agency") + RENTAL_AGENCY("rental_agency"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + HostType(String value) { + this.value = value; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Guest { + public static class Insurance { + /** Required. Price of the insurance coverage in cents. */ + @SerializedName("amount") + Long amount; + + /** Currency of the insurance amount. */ + @SerializedName("currency") + String currency; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -11172,13 +12983,25 @@ public static class Guest { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Required. Guest's full name. */ - @SerializedName("name") - String name; + /** Name of the insurance company. */ + @SerializedName("insurance_company_name") + String insuranceCompanyName; - private Guest(Map extraParams, String name) { + /** Required. Type of insurance coverage. */ + @SerializedName("insurance_type") + InsuranceType insuranceType; + + private Insurance( + Long amount, + String currency, + Map extraParams, + String insuranceCompanyName, + InsuranceType insuranceType) { + this.amount = amount; + this.currency = currency; this.extraParams = extraParams; - this.name = name; + this.insuranceCompanyName = insuranceCompanyName; + this.insuranceType = insuranceType; } public static Builder builder() { @@ -11186,22 +13009,44 @@ public static Builder builder() { } public static class Builder { + private Long amount; + + private String currency; + private Map extraParams; - private String name; + private String insuranceCompanyName; + + private InsuranceType insuranceType; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Guest build() { - return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Guest( - this.extraParams, this.name); + public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Insurance build() { + return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Insurance( + this.amount, + this.currency, + this.extraParams, + this.insuranceCompanyName, + this.insuranceType); + } + + /** Required. Price of the insurance coverage in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Currency of the insurance amount. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Guest#extraParams} for the field - * documentation. + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Insurance#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -11215,8 +13060,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Guest#extraParams} for the field - * documentation. + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Insurance#extraParams} for the + * field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -11226,24 +13071,65 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Required. Guest's full name. */ - public Builder setName(String name) { - this.name = name; + /** Name of the insurance company. */ + public Builder setInsuranceCompanyName(String insuranceCompanyName) { + this.insuranceCompanyName = insuranceCompanyName; + return this; + } + + /** Required. Type of insurance coverage. */ + public Builder setInsuranceType( + PaymentIntentCaptureParams.PaymentDetails.LodgingData.Insurance.InsuranceType + insuranceType) { + this.insuranceType = insuranceType; return this; } } + + public enum InsuranceType implements ApiRequestParams.EnumParam { + @SerializedName("bankruptcy") + BANKRUPTCY("bankruptcy"), + + @SerializedName("cancelation") + CANCELATION("cancelation"), + + @SerializedName("emergency") + EMERGENCY("emergency"), + + @SerializedName("medical") + MEDICAL("medical"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + InsuranceType(String value) { + this.value = value; + } + } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Host { - /** Address of the host. */ - @SerializedName("address") - Address address; + public static class Total { + /** Required. Total price of the lodging reservation in cents. */ + @SerializedName("amount") + Long amount; - /** Host's country of domicile. */ - @SerializedName("country_of_domicile") - String countryOfDomicile; + /** Cash advances in cents. */ + @SerializedName("cash_advances") + Long cashAdvances; + + /** Currency of the total amount. */ + @SerializedName("currency") + String currency; + + /** Discount details for the lodging. */ + @SerializedName("discounts") + Discounts discounts; + + /** Additional charges for the lodging. */ + @SerializedName("extra_charges") + List extraCharges; /** * Map of extra parameters for custom features not available in this client library. The @@ -11255,49 +13141,32 @@ public static class Host { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Reference number for the host. */ - @SerializedName("host_reference") - String hostReference; - - /** Type of host. */ - @SerializedName("host_type") - HostType hostType; - - /** Name of the lodging property or host. */ - @SerializedName("name") - String name; - - /** Total number of reservations for the host. */ - @SerializedName("number_of_reservations") - Long numberOfReservations; - - /** Property phone number. */ - @SerializedName("property_phone_number") - String propertyPhoneNumber; + /** Prepaid amount in cents. */ + @SerializedName("prepaid_amount") + Long prepaidAmount; - /** Host's registration date. */ - @SerializedName("registered_at") - Long registeredAt; + /** Tax breakdown for the lodging reservation. */ + @SerializedName("tax") + Tax tax; - private Host( - Address address, - String countryOfDomicile, + private Total( + Long amount, + Long cashAdvances, + String currency, + Discounts discounts, + List + extraCharges, Map extraParams, - String hostReference, - HostType hostType, - String name, - Long numberOfReservations, - String propertyPhoneNumber, - Long registeredAt) { - this.address = address; - this.countryOfDomicile = countryOfDomicile; + Long prepaidAmount, + Tax tax) { + this.amount = amount; + this.cashAdvances = cashAdvances; + this.currency = currency; + this.discounts = discounts; + this.extraCharges = extraCharges; this.extraParams = extraParams; - this.hostReference = hostReference; - this.hostType = hostType; - this.name = name; - this.numberOfReservations = numberOfReservations; - this.propertyPhoneNumber = propertyPhoneNumber; - this.registeredAt = registeredAt; + this.prepaidAmount = prepaidAmount; + this.tax = tax; } public static Builder builder() { @@ -11305,56 +13174,98 @@ public static Builder builder() { } public static class Builder { - private Address address; - - private String countryOfDomicile; + private Long amount; - private Map extraParams; + private Long cashAdvances; - private String hostReference; + private String currency; - private HostType hostType; + private Discounts discounts; - private String name; + private List + extraCharges; - private Long numberOfReservations; + private Map extraParams; - private String propertyPhoneNumber; + private Long prepaidAmount; - private Long registeredAt; + private Tax tax; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host build() { - return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host( - this.address, - this.countryOfDomicile, + public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total build() { + return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total( + this.amount, + this.cashAdvances, + this.currency, + this.discounts, + this.extraCharges, this.extraParams, - this.hostReference, - this.hostType, - this.name, - this.numberOfReservations, - this.propertyPhoneNumber, - this.registeredAt); + this.prepaidAmount, + this.tax); + } + + /** Required. Total price of the lodging reservation in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Cash advances in cents. */ + public Builder setCashAdvances(Long cashAdvances) { + this.cashAdvances = cashAdvances; + return this; + } + + /** Currency of the total amount. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; + } + + /** Discount details for the lodging. */ + public Builder setDiscounts( + PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Discounts discounts) { + this.discounts = discounts; + return this; } - /** Address of the host. */ - public Builder setAddress( - PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host.Address address) { - this.address = address; + /** + * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total#extraCharges} for the field + * documentation. + */ + public Builder addExtraCharge( + PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge element) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.add(element); return this; } - /** Host's country of domicile. */ - public Builder setCountryOfDomicile(String countryOfDomicile) { - this.countryOfDomicile = countryOfDomicile; + /** + * Add all elements to `extraCharges` list. A list is initialized for the first + * `add/addAll` call, and subsequent calls adds additional elements to the original list. + * See {@link PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total#extraCharges} + * for the field documentation. + */ + public Builder addAllExtraCharge( + List + elements) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.addAll(elements); return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total#extraParams} for the field + * documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -11367,8 +13278,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total#extraParams} for the field + * documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -11378,58 +13290,228 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Reference number for the host. */ - public Builder setHostReference(String hostReference) { - this.hostReference = hostReference; + /** Prepaid amount in cents. */ + public Builder setPrepaidAmount(Long prepaidAmount) { + this.prepaidAmount = prepaidAmount; return this; } - /** Type of host. */ - public Builder setHostType( - PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host.HostType hostType) { - this.hostType = hostType; + /** Tax breakdown for the lodging reservation. */ + public Builder setTax( + PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax tax) { + this.tax = tax; return this; } + } - /** Name of the lodging property or host. */ - public Builder setName(String name) { - this.name = name; - return this; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Discounts { + /** Corporate client discount code. */ + @SerializedName("corporate_client_code") + String corporateClientCode; + + /** Coupon code. */ + @SerializedName("coupon") + String coupon; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Discounts( + String corporateClientCode, String coupon, Map extraParams) { + this.corporateClientCode = corporateClientCode; + this.coupon = coupon; + this.extraParams = extraParams; } - /** Total number of reservations for the host. */ - public Builder setNumberOfReservations(Long numberOfReservations) { - this.numberOfReservations = numberOfReservations; - return this; + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String corporateClientCode; + + private String coupon; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Discounts build() { + return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Discounts( + this.corporateClientCode, this.coupon, this.extraParams); + } + + /** Corporate client discount code. */ + public Builder setCorporateClientCode(String corporateClientCode) { + this.corporateClientCode = corporateClientCode; + return this; + } + + /** Coupon code. */ + public Builder setCoupon(String coupon) { + this.coupon = coupon; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ExtraCharge { + /** Amount of the extra charge in cents. */ + @SerializedName("amount") + Long amount; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Type of extra charge. */ + @SerializedName("type") + Type type; + + private ExtraCharge(Long amount, Map extraParams, Type type) { + this.amount = amount; + this.extraParams = extraParams; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private Map extraParams; + + private Type type; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge build() { + return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge( + this.amount, this.extraParams, this.type); + } + + /** Amount of the extra charge in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Type of extra charge. */ + public Builder setType( + PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge.Type type) { + this.type = type; + return this; + } } - /** Property phone number. */ - public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { - this.propertyPhoneNumber = propertyPhoneNumber; - return this; - } + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("gift_shop") + GIFT_SHOP("gift_shop"), + + @SerializedName("laundry") + LAUNDRY("laundry"), + + @SerializedName("mini_bar") + MINI_BAR("mini_bar"), + + @SerializedName("other") + OTHER("other"), + + @SerializedName("phone") + PHONE("phone"), + + @SerializedName("restaurant") + RESTAURANT("restaurant"); - /** Host's registration date. */ - public Builder setRegisteredAt(Long registeredAt) { - this.registeredAt = registeredAt; - return this; + @Getter(onMethod_ = {@Override}) + private final String value; + + Type(String value) { + this.value = value; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Address { - /** Required. City, district, suburb, town, or village. */ - @SerializedName("city") - String city; - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - @SerializedName("country") - String country; - + public static class Tax { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -11440,42 +13522,22 @@ public static class Address { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** - * Required. Address line 1, such as the street, PO Box, or company name. - */ - @SerializedName("line1") - String line1; - - /** Address line 2, such as the apartment, suite, unit, or building. */ - @SerializedName("line2") - String line2; - - /** Required. ZIP or postal code. */ - @SerializedName("postal_code") - String postalCode; + /** Indicates whether the transaction is tax exempt. */ + @SerializedName("tax_exempt_indicator") + Boolean taxExemptIndicator; - /** - * State, county, province, or region (ISO 3166-2). - */ - @SerializedName("state") - String state; + /** Tax details. */ + @SerializedName("taxes") + List taxes; - private Address( - String city, - String country, + private Tax( Map extraParams, - String line1, - String line2, - String postalCode, - String state) { - this.city = city; - this.country = country; + Boolean taxExemptIndicator, + List + taxes) { this.extraParams = extraParams; - this.line1 = line1; - this.line2 = line2; - this.postalCode = postalCode; - this.state = state; + this.taxExemptIndicator = taxExemptIndicator; + this.taxes = taxes; } public static Builder builder() { @@ -11483,53 +13545,25 @@ public static Builder builder() { } public static class Builder { - private String city; - - private String country; - private Map extraParams; - private String line1; - - private String line2; - - private String postalCode; + private Boolean taxExemptIndicator; - private String state; + private List + taxes; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host.Address build() { - return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host.Address( - this.city, - this.country, - this.extraParams, - this.line1, - this.line2, - this.postalCode, - this.state); - } - - /** Required. City, district, suburb, town, or village. */ - public Builder setCity(String city) { - this.city = city; - return this; - } - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - public Builder setCountry(String country) { - this.country = country; - return this; + public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax build() { + return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax( + this.extraParams, this.taxExemptIndicator, this.taxes); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host.Address#extraParams} for - * the field documentation. + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -11543,8 +13577,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Host.Address#extraParams} for - * the field documentation. + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the + * field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -11554,228 +13588,261 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Required. Address line 1, such as the street, PO Box, or company - * name. - */ - public Builder setLine1(String line1) { - this.line1 = line1; + /** Indicates whether the transaction is tax exempt. */ + public Builder setTaxExemptIndicator(Boolean taxExemptIndicator) { + this.taxExemptIndicator = taxExemptIndicator; return this; } - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(String line2) { - this.line2 = line2; + /** + * Add an element to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field + * documentation. + */ + public Builder addTax( + PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax element) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.add(element); return this; } - /** Required. ZIP or postal code. */ - public Builder setPostalCode(String postalCode) { - this.postalCode = postalCode; + /** + * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field + * documentation. + */ + public Builder addAllTax( + List + elements) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.addAll(elements); return this; } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class InnerTax { + /** Tax amount in cents. */ + @SerializedName("amount") + Long amount; /** - * State, county, province, or region (ISO 3166-2). + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. */ - public Builder setState(String state) { - this.state = state; - return this; + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Tax rate. */ + @SerializedName("rate") + Long rate; + + /** Type of tax applied. */ + @SerializedName("type") + String type; + + private InnerTax(Long amount, Map extraParams, Long rate, String type) { + this.amount = amount; + this.extraParams = extraParams; + this.rate = rate; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private Map extraParams; + + private Long rate; + + private String type; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax + build() { + return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax( + this.amount, this.extraParams, this.rate, this.type); + } + + /** Tax amount in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Tax rate. */ + public Builder setRate(Long rate) { + this.rate = rate; + return this; + } + + /** Type of tax applied. */ + public Builder setType(String type) { + this.type = type; + return this; + } } } } + } + } - public enum HostType implements ApiRequestParams.EnumParam { - @SerializedName("hostel") - HOSTEL("hostel"), - - @SerializedName("hotel") - HOTEL("hotel"), - - @SerializedName("owner") - OWNER("owner"), + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Account funding transaction details including sender and beneficiary information. */ + @SerializedName("account_funding") + Object accountFunding; - @SerializedName("rental_agency") - RENTAL_AGENCY("rental_agency"); + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - @Getter(onMethod_ = {@Override}) - private final String value; + /** The type of money services transaction. */ + @SerializedName("transaction_type") + ApiRequestParams.EnumParam transactionType; - HostType(String value) { - this.value = value; - } - } + private MoneyServices( + Object accountFunding, + Map extraParams, + ApiRequestParams.EnumParam transactionType) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + this.transactionType = transactionType; } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Insurance { - /** Required. Price of the insurance coverage in cents. */ - @SerializedName("amount") - Long amount; - - /** Currency of the insurance amount. */ - @SerializedName("currency") - String currency; + public static Builder builder() { + return new Builder(); + } - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public static class Builder { + private Object accountFunding; - /** Name of the insurance company. */ - @SerializedName("insurance_company_name") - String insuranceCompanyName; + private Map extraParams; - /** Required. Type of insurance coverage. */ - @SerializedName("insurance_type") - InsuranceType insuranceType; + private ApiRequestParams.EnumParam transactionType; - private Insurance( - Long amount, - String currency, - Map extraParams, - String insuranceCompanyName, - InsuranceType insuranceType) { - this.amount = amount; - this.currency = currency; - this.extraParams = extraParams; - this.insuranceCompanyName = insuranceCompanyName; - this.insuranceType = insuranceType; + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.MoneyServices build() { + return new PaymentIntentCaptureParams.PaymentDetails.MoneyServices( + this.accountFunding, this.extraParams, this.transactionType); } - public static Builder builder() { - return new Builder(); + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding( + PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { + this.accountFunding = accountFunding; + return this; } - public static class Builder { - private Long amount; - - private String currency; - - private Map extraParams; - - private String insuranceCompanyName; - - private InsuranceType insuranceType; - - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Insurance build() { - return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Insurance( - this.amount, - this.currency, - this.extraParams, - this.insuranceCompanyName, - this.insuranceType); - } - - /** Required. Price of the insurance coverage in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } - - /** Currency of the insurance amount. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; - } - - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Insurance#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } - - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Insurance#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding(EmptyParam accountFunding) { + this.accountFunding = accountFunding; + return this; + } - /** Name of the insurance company. */ - public Builder setInsuranceCompanyName(String insuranceCompanyName) { - this.insuranceCompanyName = insuranceCompanyName; - return this; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.MoneyServices#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.put(key, value); + return this; + } - /** Required. Type of insurance coverage. */ - public Builder setInsuranceType( - PaymentIntentCaptureParams.PaymentDetails.LodgingData.Insurance.InsuranceType - insuranceType) { - this.insuranceType = insuranceType; - return this; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCaptureParams.PaymentDetails.MoneyServices#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.putAll(map); + return this; } - public enum InsuranceType implements ApiRequestParams.EnumParam { - @SerializedName("bankruptcy") - BANKRUPTCY("bankruptcy"), - - @SerializedName("cancelation") - CANCELATION("cancelation"), - - @SerializedName("emergency") - EMERGENCY("emergency"), - - @SerializedName("medical") - MEDICAL("medical"); - - @Getter(onMethod_ = {@Override}) - private final String value; + /** The type of money services transaction. */ + public Builder setTransactionType( + PaymentIntentCaptureParams.PaymentDetails.MoneyServices.TransactionType + transactionType) { + this.transactionType = transactionType; + return this; + } - InsuranceType(String value) { - this.value = value; - } + /** The type of money services transaction. */ + public Builder setTransactionType(EmptyParam transactionType) { + this.transactionType = transactionType; + return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Total { - /** Required. Total price of the lodging reservation in cents. */ - @SerializedName("amount") - Long amount; - - /** Cash advances in cents. */ - @SerializedName("cash_advances") - Long cashAdvances; - - /** Currency of the total amount. */ - @SerializedName("currency") - String currency; - - /** Discount details for the lodging. */ - @SerializedName("discounts") - Discounts discounts; + public static class AccountFunding { + /** ID of the Account representing the beneficiary in this account funding transaction. */ + @SerializedName("beneficiary_account") + String beneficiaryAccount; - /** Additional charges for the lodging. */ - @SerializedName("extra_charges") - List extraCharges; + /** Inline identity details for the beneficiary of this account funding transaction. */ + @SerializedName("beneficiary_details") + Object beneficiaryDetails; /** * Map of extra parameters for custom features not available in this client library. The @@ -11787,32 +13854,25 @@ public static class Total { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Prepaid amount in cents. */ - @SerializedName("prepaid_amount") - Long prepaidAmount; - - /** Tax breakdown for the lodging reservation. */ - @SerializedName("tax") - Tax tax; + /** ID of the Account representing the sender in this account funding transaction. */ + @SerializedName("sender_account") + String senderAccount; - private Total( - Long amount, - Long cashAdvances, - String currency, - Discounts discounts, - List - extraCharges, + /** Inline identity details for the sender of this account funding transaction. */ + @SerializedName("sender_details") + Object senderDetails; + + private AccountFunding( + String beneficiaryAccount, + Object beneficiaryDetails, Map extraParams, - Long prepaidAmount, - Tax tax) { - this.amount = amount; - this.cashAdvances = cashAdvances; - this.currency = currency; - this.discounts = discounts; - this.extraCharges = extraCharges; + String senderAccount, + Object senderDetails) { + this.beneficiaryAccount = beneficiaryAccount; + this.beneficiaryDetails = beneficiaryDetails; this.extraParams = extraParams; - this.prepaidAmount = prepaidAmount; - this.tax = tax; + this.senderAccount = senderAccount; + this.senderDetails = senderDetails; } public static Builder builder() { @@ -11820,89 +13880,44 @@ public static Builder builder() { } public static class Builder { - private Long amount; - - private Long cashAdvances; - - private String currency; - - private Discounts discounts; + private String beneficiaryAccount; - private List - extraCharges; + private Object beneficiaryDetails; private Map extraParams; - private Long prepaidAmount; + private String senderAccount; - private Tax tax; + private Object senderDetails; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total build() { - return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total( - this.amount, - this.cashAdvances, - this.currency, - this.discounts, - this.extraCharges, + public PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding build() { + return new PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding( + this.beneficiaryAccount, + this.beneficiaryDetails, this.extraParams, - this.prepaidAmount, - this.tax); - } - - /** Required. Total price of the lodging reservation in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; + this.senderAccount, + this.senderDetails); } - /** Cash advances in cents. */ - public Builder setCashAdvances(Long cashAdvances) { - this.cashAdvances = cashAdvances; - return this; - } - - /** Currency of the total amount. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; - } - - /** Discount details for the lodging. */ - public Builder setDiscounts( - PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Discounts discounts) { - this.discounts = discounts; + /** ID of the Account representing the beneficiary in this account funding transaction. */ + public Builder setBeneficiaryAccount(String beneficiaryAccount) { + this.beneficiaryAccount = beneficiaryAccount; return this; } - /** - * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total#extraCharges} for the field - * documentation. - */ - public Builder addExtraCharge( - PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge element) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.add(element); + /** Inline identity details for the beneficiary of this account funding transaction. */ + public Builder setBeneficiaryDetails( + PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails + beneficiaryDetails) { + this.beneficiaryDetails = beneficiaryDetails; return this; } - /** - * Add all elements to `extraCharges` list. A list is initialized for the first - * `add/addAll` call, and subsequent calls adds additional elements to the original list. - * See {@link PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total#extraCharges} - * for the field documentation. - */ - public Builder addAllExtraCharge( - List - elements) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.addAll(elements); + /** Inline identity details for the beneficiary of this account funding transaction. */ + public Builder setBeneficiaryDetails(EmptyParam beneficiaryDetails) { + this.beneficiaryDetails = beneficiaryDetails; return this; } @@ -11910,8 +13925,8 @@ public Builder addAllExtraCharge( * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total#extraParams} for the field - * documentation. + * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -11925,8 +13940,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total#extraParams} for the field - * documentation. + * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -11936,30 +13951,41 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Prepaid amount in cents. */ - public Builder setPrepaidAmount(Long prepaidAmount) { - this.prepaidAmount = prepaidAmount; + /** ID of the Account representing the sender in this account funding transaction. */ + public Builder setSenderAccount(String senderAccount) { + this.senderAccount = senderAccount; return this; } - /** Tax breakdown for the lodging reservation. */ - public Builder setTax( - PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax tax) { - this.tax = tax; + /** Inline identity details for the sender of this account funding transaction. */ + public Builder setSenderDetails( + PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + senderDetails) { + this.senderDetails = senderDetails; + return this; + } + + /** Inline identity details for the sender of this account funding transaction. */ + public Builder setSenderDetails(EmptyParam senderDetails) { + this.senderDetails = senderDetails; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Discounts { - /** Corporate client discount code. */ - @SerializedName("corporate_client_code") - String corporateClientCode; + public static class BeneficiaryDetails { + /** Address. */ + @SerializedName("address") + Address address; - /** Coupon code. */ - @SerializedName("coupon") - String coupon; + /** Date of birth. */ + @SerializedName("date_of_birth") + DateOfBirth dateOfBirth; + + /** Email address. */ + @SerializedName("email") + String email; /** * Map of extra parameters for custom features not available in this client library. The @@ -11971,11 +13997,27 @@ public static class Discounts { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private Discounts( - String corporateClientCode, String coupon, Map extraParams) { - this.corporateClientCode = corporateClientCode; - this.coupon = coupon; + /** Full name. */ + @SerializedName("name") + String name; + + /** Phone number. */ + @SerializedName("phone") + String phone; + + private BeneficiaryDetails( + Address address, + DateOfBirth dateOfBirth, + String email, + Map extraParams, + String name, + String phone) { + this.address = address; + this.dateOfBirth = dateOfBirth; + this.email = email; this.extraParams = extraParams; + this.name = name; + this.phone = phone; } public static Builder builder() { @@ -11983,27 +14025,53 @@ public static Builder builder() { } public static class Builder { - private String corporateClientCode; + private Address address; - private String coupon; + private DateOfBirth dateOfBirth; + + private String email; private Map extraParams; + private String name; + + private String phone; + /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Discounts build() { - return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Discounts( - this.corporateClientCode, this.coupon, this.extraParams); + public PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails + build() { + return new PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails( + this.address, + this.dateOfBirth, + this.email, + this.extraParams, + this.name, + this.phone); } - /** Corporate client discount code. */ - public Builder setCorporateClientCode(String corporateClientCode) { - this.corporateClientCode = corporateClientCode; + /** Address. */ + public Builder setAddress( + PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.Address + address) { + this.address = address; return this; } - /** Coupon code. */ - public Builder setCoupon(String coupon) { - this.coupon = coupon; + /** Date of birth. */ + public Builder setDateOfBirth( + PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.DateOfBirth + dateOfBirth) { + this.dateOfBirth = dateOfBirth; + return this; + } + + /** Email address. */ + public Builder setEmail(String email) { + this.email = email; return this; } @@ -12011,7 +14079,7 @@ public Builder setCoupon(String coupon) { * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} + * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails#extraParams} * for the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -12026,138 +14094,318 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} + * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails#extraParams} * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { this.extraParams = new HashMap<>(); } - this.extraParams.putAll(map); - return this; - } - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class ExtraCharge { - /** Amount of the extra charge in cents. */ - @SerializedName("amount") - Long amount; + this.extraParams.putAll(map); + return this; + } + + /** Full name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** Phone number. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Address { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + String city; + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + String country; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Address line 1, such as the street, PO Box, or company name. */ + @SerializedName("line1") + String line1; + + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; + + /** ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; + + private Address( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String city; + + private String country; + + private Map extraParams; + + private String line1; + + private String line2; + + private String postalCode; + + private String state; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.Address + build() { + return new PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } + + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.Address#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.Address#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } - /** Type of extra charge. */ - @SerializedName("type") - Type type; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } - private ExtraCharge(Long amount, Map extraParams, Type type) { - this.amount = amount; - this.extraParams = extraParams; - this.type = type; - } + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - public static Builder builder() { - return new Builder(); + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + } } - public static class Builder { - private Long amount; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class DateOfBirth { + /** Required. Day of birth, between 1 and 31. */ + @SerializedName("day") + Long day; - private Map extraParams; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private Type type; + /** Required. Month of birth, between 1 and 12. */ + @SerializedName("month") + Long month; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge build() { - return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge( - this.amount, this.extraParams, this.type); - } + /** Required. Four-digit year of birth. */ + @SerializedName("year") + Long year; - /** Amount of the extra charge in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; + private DateOfBirth(Long day, Map extraParams, Long month, Long year) { + this.day = day; + this.extraParams = extraParams; + this.month = month; + this.year = year; } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; + public static Builder builder() { + return new Builder(); } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + public static class Builder { + private Long day; - /** Type of extra charge. */ - public Builder setType( - PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.ExtraCharge.Type type) { - this.type = type; - return this; - } - } + private Map extraParams; - public enum Type implements ApiRequestParams.EnumParam { - @SerializedName("gift_shop") - GIFT_SHOP("gift_shop"), + private Long month; - @SerializedName("laundry") - LAUNDRY("laundry"), + private Long year; - @SerializedName("mini_bar") - MINI_BAR("mini_bar"), + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.DateOfBirth + build() { + return new PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.DateOfBirth( + this.day, this.extraParams, this.month, this.year); + } - @SerializedName("other") - OTHER("other"), + /** Required. Day of birth, between 1 and 31. */ + public Builder setDay(Long day) { + this.day = day; + return this; + } - @SerializedName("phone") - PHONE("phone"), + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - @SerializedName("restaurant") - RESTAURANT("restaurant"); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** Required. Month of birth, between 1 and 12. */ + public Builder setMonth(Long month) { + this.month = month; + return this; + } - Type(String value) { - this.value = value; + /** Required. Four-digit year of birth. */ + public Builder setYear(Long year) { + this.year = year; + return this; + } } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Tax { + public static class SenderDetails { + /** Address. */ + @SerializedName("address") + Address address; + + /** Date of birth. */ + @SerializedName("date_of_birth") + DateOfBirth dateOfBirth; + + /** Email address. */ + @SerializedName("email") + String email; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -12168,22 +14416,27 @@ public static class Tax { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Indicates whether the transaction is tax exempt. */ - @SerializedName("tax_exempt_indicator") - Boolean taxExemptIndicator; + /** Full name. */ + @SerializedName("name") + String name; - /** Tax details. */ - @SerializedName("taxes") - List taxes; + /** Phone number. */ + @SerializedName("phone") + String phone; - private Tax( + private SenderDetails( + Address address, + DateOfBirth dateOfBirth, + String email, Map extraParams, - Boolean taxExemptIndicator, - List - taxes) { + String name, + String phone) { + this.address = address; + this.dateOfBirth = dateOfBirth; + this.email = email; this.extraParams = extraParams; - this.taxExemptIndicator = taxExemptIndicator; - this.taxes = taxes; + this.name = name; + this.phone = phone; } public static Builder builder() { @@ -12191,25 +14444,62 @@ public static Builder builder() { } public static class Builder { + private Address address; + + private DateOfBirth dateOfBirth; + + private String email; + private Map extraParams; - private Boolean taxExemptIndicator; + private String name; - private List - taxes; + private String phone; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax build() { - return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax( - this.extraParams, this.taxExemptIndicator, this.taxes); + public PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails + build() { + return new PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails( + this.address, + this.dateOfBirth, + this.email, + this.extraParams, + this.name, + this.phone); + } + + /** Address. */ + public Builder setAddress( + PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + .Address + address) { + this.address = address; + return this; + } + + /** Date of birth. */ + public Builder setDateOfBirth( + PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + .DateOfBirth + dateOfBirth) { + this.dateOfBirth = dateOfBirth; + return this; + } + + /** Email address. */ + public Builder setEmail(String email) { + this.email = email; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the - * field documentation. + * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -12223,8 +14513,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the - * field documentation. + * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -12234,50 +14524,32 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Indicates whether the transaction is tax exempt. */ - public Builder setTaxExemptIndicator(Boolean taxExemptIndicator) { - this.taxExemptIndicator = taxExemptIndicator; - return this; - } - - /** - * Add an element to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addTax( - PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax element) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.add(element); + /** Full name. */ + public Builder setName(String name) { + this.name = name; return this; } - /** - * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addAllTax( - List - elements) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.addAll(elements); + /** Phone number. */ + public Builder setPhone(String phone) { + this.phone = phone; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class InnerTax { - /** Tax amount in cents. */ - @SerializedName("amount") - Long amount; + public static class Address { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + String city; + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + String country; /** * Map of extra parameters for custom features not available in this client library. The @@ -12289,19 +14561,40 @@ public static class InnerTax { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Tax rate. */ - @SerializedName("rate") - Long rate; + /** Address line 1, such as the street, PO Box, or company name. */ + @SerializedName("line1") + String line1; - /** Type of tax applied. */ - @SerializedName("type") - String type; + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; - private InnerTax(Long amount, Map extraParams, Long rate, String type) { - this.amount = amount; + /** ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; + + private Address( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; this.extraParams = extraParams; - this.rate = rate; - this.type = type; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; } public static Builder builder() { @@ -12309,24 +14602,47 @@ public static Builder builder() { } public static class Builder { - private Long amount; + private String city; + + private String country; private Map extraParams; - private Long rate; + private String line1; - private String type; + private String line2; + + private String postalCode; + + private String state; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax + public PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.Address build() { - return new PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax( - this.amount, this.extraParams, this.rate, this.type); + return new PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); } - /** Tax amount in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; return this; } @@ -12334,7 +14650,7 @@ public Builder setAmount(Long amount) { * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} + * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.Address#extraParams} * for the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -12349,7 +14665,7 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the * first `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} + * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.Address#extraParams} * for the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -12360,175 +14676,136 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Tax rate. */ - public Builder setRate(Long rate) { - this.rate = rate; + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(String line1) { + this.line1 = line1; return this; } - /** Type of tax applied. */ - public Builder setType(String type) { - this.type = type; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; return this; } - } - } - } - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class MoneyServices { - /** Account funding transaction details including sender and beneficiary information. */ - @SerializedName("account_funding") - Object accountFunding; - - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) - * name in this param object. Effectively, this map is flattened to its parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; - - /** The type of money services transaction. */ - @SerializedName("transaction_type") - TransactionType transactionType; - private MoneyServices( - Object accountFunding, Map extraParams, TransactionType transactionType) { - this.accountFunding = accountFunding; - this.extraParams = extraParams; - this.transactionType = transactionType; - } + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - public static Builder builder() { - return new Builder(); - } + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + } + } - public static class Builder { - private Object accountFunding; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class DateOfBirth { + /** Required. Day of birth, between 1 and 31. */ + @SerializedName("day") + Long day; - private Map extraParams; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private TransactionType transactionType; + /** Required. Month of birth, between 1 and 12. */ + @SerializedName("month") + Long month; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.MoneyServices build() { - return new PaymentIntentCaptureParams.PaymentDetails.MoneyServices( - this.accountFunding, this.extraParams, this.transactionType); - } + /** Required. Four-digit year of birth. */ + @SerializedName("year") + Long year; - /** Account funding transaction details including sender and beneficiary information. */ - public Builder setAccountFunding( - PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { - this.accountFunding = accountFunding; - return this; - } + private DateOfBirth(Long day, Map extraParams, Long month, Long year) { + this.day = day; + this.extraParams = extraParams; + this.month = month; + this.year = year; + } - /** Account funding transaction details including sender and beneficiary information. */ - public Builder setAccountFunding(EmptyParam accountFunding) { - this.accountFunding = accountFunding; - return this; - } + public static Builder builder() { + return new Builder(); + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCaptureParams.PaymentDetails.MoneyServices#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + public static class Builder { + private Long day; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCaptureParams.PaymentDetails.MoneyServices#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + private Map extraParams; - /** The type of money services transaction. */ - public Builder setTransactionType( - PaymentIntentCaptureParams.PaymentDetails.MoneyServices.TransactionType - transactionType) { - this.transactionType = transactionType; - return this; - } - } + private Long month; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class AccountFunding { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private Long year; - private AccountFunding(Map extraParams) { - this.extraParams = extraParams; - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.DateOfBirth + build() { + return new PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.DateOfBirth(this.day, this.extraParams, this.month, this.year); + } - public static Builder builder() { - return new Builder(); - } + /** Required. Day of birth, between 1 and 31. */ + public Builder setDay(Long day) { + this.day = day; + return this; + } - public static class Builder { - private Map extraParams; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding build() { - return new PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding( - this.extraParams); - } + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Required. Month of birth, between 1 and 12. */ + public Builder setMonth(Long month) { + this.month = month; + return this; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** Required. Four-digit year of birth. */ + public Builder setYear(Long year) { + this.year = year; + return this; + } } - this.extraParams.putAll(map); - return this; } } } diff --git a/src/main/java/com/stripe/param/PaymentIntentConfirmParams.java b/src/main/java/com/stripe/param/PaymentIntentConfirmParams.java index b131b51f2ca..f31102800e6 100644 --- a/src/main/java/com/stripe/param/PaymentIntentConfirmParams.java +++ b/src/main/java/com/stripe/param/PaymentIntentConfirmParams.java @@ -1145,6 +1145,13 @@ public static class LineItem { @SerializedName("quantity") Long quantity; + /** + * The number of decimal places implied in the quantity. For example, if quantity is 10000 and + * quantity_precision is 2, the actual quantity is 100.00. Defaults to 0 if not provided. + */ + @SerializedName("quantity_precision") + Long quantityPrecision; + /** Contains information about the tax on the item. */ @SerializedName("tax") Tax tax; @@ -1168,6 +1175,7 @@ private LineItem( String productCode, String productName, Long quantity, + Long quantityPrecision, Tax tax, Long unitCost, String unitOfMeasure) { @@ -1177,6 +1185,7 @@ private LineItem( this.productCode = productCode; this.productName = productName; this.quantity = quantity; + this.quantityPrecision = quantityPrecision; this.tax = tax; this.unitCost = unitCost; this.unitOfMeasure = unitOfMeasure; @@ -1199,6 +1208,8 @@ public static class Builder { private Long quantity; + private Long quantityPrecision; + private Tax tax; private Long unitCost; @@ -1214,6 +1225,7 @@ public PaymentIntentConfirmParams.AmountDetails.LineItem build() { this.productCode, this.productName, this.quantity, + this.quantityPrecision, this.tax, this.unitCost, this.unitOfMeasure); @@ -1298,6 +1310,16 @@ public Builder setQuantity(Long quantity) { return this; } + /** + * The number of decimal places implied in the quantity. For example, if quantity is 10000 + * and quantity_precision is 2, the actual quantity is 100.00. Defaults to 0 if not + * provided. + */ + public Builder setQuantityPrecision(Long quantityPrecision) { + this.quantityPrecision = quantityPrecision; + return this; + } + /** Contains information about the tax on the item. */ public Builder setTax(PaymentIntentConfirmParams.AmountDetails.LineItem.Tax tax) { this.tax = tax; @@ -1490,9 +1512,14 @@ public static class Card { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private Card(String commodityCode, Map extraParams) { + /** Fleet data for this line item. */ + @SerializedName("fleet_data") + FleetData fleetData; + + private Card(String commodityCode, Map extraParams, FleetData fleetData) { this.commodityCode = commodityCode; this.extraParams = extraParams; + this.fleetData = fleetData; } public static Builder builder() { @@ -1504,11 +1531,13 @@ public static class Builder { private Map extraParams; + private FleetData fleetData; + /** Finalize and obtain parameter instance from this builder. */ public PaymentIntentConfirmParams.AmountDetails.LineItem.PaymentMethodOptions.Card build() { return new PaymentIntentConfirmParams.AmountDetails.LineItem.PaymentMethodOptions - .Card(this.commodityCode, this.extraParams); + .Card(this.commodityCode, this.extraParams, this.fleetData); } /** @@ -1549,6 +1578,267 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } + + /** Fleet data for this line item. */ + public Builder setFleetData( + PaymentIntentConfirmParams.AmountDetails.LineItem.PaymentMethodOptions.Card + .FleetData + fleetData) { + this.fleetData = fleetData; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class FleetData { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Required. The type of product being purchased at this line item. */ + @SerializedName("product_type") + ProductType productType; + + /** The type of service received at the acceptor location. */ + @SerializedName("service_type") + ServiceType serviceType; + + private FleetData( + Map extraParams, ProductType productType, ServiceType serviceType) { + this.extraParams = extraParams; + this.productType = productType; + this.serviceType = serviceType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private ProductType productType; + + private ServiceType serviceType; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.AmountDetails.LineItem.PaymentMethodOptions.Card + .FleetData + build() { + return new PaymentIntentConfirmParams.AmountDetails.LineItem.PaymentMethodOptions + .Card.FleetData(this.extraParams, this.productType, this.serviceType); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.AmountDetails.LineItem.PaymentMethodOptions.Card.FleetData#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.AmountDetails.LineItem.PaymentMethodOptions.Card.FleetData#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. The type of product being purchased at this line item. + */ + public Builder setProductType( + PaymentIntentConfirmParams.AmountDetails.LineItem.PaymentMethodOptions.Card + .FleetData.ProductType + productType) { + this.productType = productType; + return this; + } + + /** The type of service received at the acceptor location. */ + public Builder setServiceType( + PaymentIntentConfirmParams.AmountDetails.LineItem.PaymentMethodOptions.Card + .FleetData.ServiceType + serviceType) { + this.serviceType = serviceType; + return this; + } + } + + public enum ProductType implements ApiRequestParams.EnumParam { + @SerializedName("air_conditioning_service") + AIR_CONDITIONING_SERVICE("air_conditioning_service"), + + @SerializedName("alcohol") + ALCOHOL("alcohol"), + + @SerializedName("aviation_fuel_premium") + AVIATION_FUEL_PREMIUM("aviation_fuel_premium"), + + @SerializedName("aviation_fuel_regular") + AVIATION_FUEL_REGULAR("aviation_fuel_regular"), + + @SerializedName("car_care_detailing") + CAR_CARE_DETAILING("car_care_detailing"), + + @SerializedName("compressed_natural_gas") + COMPRESSED_NATURAL_GAS("compressed_natural_gas"), + + @SerializedName("deli") + DELI("deli"), + + @SerializedName("food_service") + FOOD_SERVICE("food_service"), + + @SerializedName("green_gasoline_mid_plus") + GREEN_GASOLINE_MID_PLUS("green_gasoline_mid_plus"), + + @SerializedName("green_gasoline_premium_super") + GREEN_GASOLINE_PREMIUM_SUPER("green_gasoline_premium_super"), + + @SerializedName("green_gasoline_regular") + GREEN_GASOLINE_REGULAR("green_gasoline_regular"), + + @SerializedName("grocery") + GROCERY("grocery"), + + @SerializedName("liquid_natural_gas") + LIQUID_NATURAL_GAS("liquid_natural_gas"), + + @SerializedName("liquid_propane_gas") + LIQUID_PROPANE_GAS("liquid_propane_gas"), + + @SerializedName("lodging") + LODGING("lodging"), + + @SerializedName("marine_diesel") + MARINE_DIESEL("marine_diesel"), + + @SerializedName("marine_fuel") + MARINE_FUEL("marine_fuel"), + + @SerializedName("merchandise") + MERCHANDISE("merchandise"), + + @SerializedName("mid_plus") + MID_PLUS("mid_plus"), + + @SerializedName("mid_plus_ethanol") + MID_PLUS_ETHANOL("mid_plus_ethanol"), + + @SerializedName("miscellaneous_aviation_products_services") + MISCELLANEOUS_AVIATION_PRODUCTS_SERVICES("miscellaneous_aviation_products_services"), + + @SerializedName("miscellaneous_fuel") + MISCELLANEOUS_FUEL("miscellaneous_fuel"), + + @SerializedName("miscellaneous_marine_products_services") + MISCELLANEOUS_MARINE_PRODUCTS_SERVICES("miscellaneous_marine_products_services"), + + @SerializedName("miscellaneous_vehicle_products_services") + MISCELLANEOUS_VEHICLE_PRODUCTS_SERVICES("miscellaneous_vehicle_products_services"), + + @SerializedName("packaged_beverage") + PACKAGED_BEVERAGE("packaged_beverage"), + + @SerializedName("premium_diesel") + PREMIUM_DIESEL("premium_diesel"), + + @SerializedName("premium_super") + PREMIUM_SUPER("premium_super"), + + @SerializedName("premium_super_ethanol") + PREMIUM_SUPER_ETHANOL("premium_super_ethanol"), + + @SerializedName("preventative_maintenance") + PREVENTATIVE_MAINTENANCE("preventative_maintenance"), + + @SerializedName("regular") + REGULAR("regular"), + + @SerializedName("regular_diesel") + REGULAR_DIESEL("regular_diesel"), + + @SerializedName("regular_ethanol") + REGULAR_ETHANOL("regular_ethanol"), + + @SerializedName("repairs") + REPAIRS("repairs"), + + @SerializedName("self_service_car_wash") + SELF_SERVICE_CAR_WASH("self_service_car_wash"), + + @SerializedName("shower") + SHOWER("shower"), + + @SerializedName("store_service") + STORE_SERVICE("store_service"), + + @SerializedName("tobacco") + TOBACCO("tobacco"), + + @SerializedName("vehicle_accessories") + VEHICLE_ACCESSORIES("vehicle_accessories"), + + @SerializedName("vehicle_parking") + VEHICLE_PARKING("vehicle_parking"), + + @SerializedName("vehicle_parts") + VEHICLE_PARTS("vehicle_parts"), + + @SerializedName("wash_out") + WASH_OUT("wash_out"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ProductType(String value) { + this.value = value; + } + } + + public enum ServiceType implements ApiRequestParams.EnumParam { + @SerializedName("full_service") + FULL_SERVICE("full_service"), + + @SerializedName("high_speed_diesel") + HIGH_SPEED_DIESEL("high_speed_diesel"), + + @SerializedName("non_fuel_only") + NON_FUEL_ONLY("non_fuel_only"), + + @SerializedName("self_service") + SELF_SERVICE("self_service"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ServiceType(String value) { + this.value = value; + } + } } } @@ -2977,6 +3267,10 @@ public static class PaymentDetails { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; + /** Fleet data for this PaymentIntent. */ + @SerializedName("fleet_data") + Object fleetData; + /** Flight reservation details for this PaymentIntent. */ @SerializedName("flight") Flight flight; @@ -3019,6 +3313,7 @@ private PaymentDetails( Object customerReference, EventDetails eventDetails, Map extraParams, + Object fleetData, Flight flight, Object flightData, Lodging lodging, @@ -3032,6 +3327,7 @@ private PaymentDetails( this.customerReference = customerReference; this.eventDetails = eventDetails; this.extraParams = extraParams; + this.fleetData = fleetData; this.flight = flight; this.flightData = flightData; this.lodging = lodging; @@ -3058,6 +3354,8 @@ public static class Builder { private Map extraParams; + private Object fleetData; + private Flight flight; private Object flightData; @@ -3081,6 +3379,7 @@ public PaymentIntentConfirmParams.PaymentDetails build() { this.customerReference, this.eventDetails, this.extraParams, + this.fleetData, this.flight, this.flightData, this.lodging, @@ -3205,6 +3504,49 @@ public Builder putAllExtraParam(Map map) { return this; } + /** + * Add an element to `fleetData` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails#fleetData} for the field documentation. + */ + @SuppressWarnings("unchecked") + public Builder addFleetData(PaymentIntentConfirmParams.PaymentDetails.FleetData element) { + if (this.fleetData == null || this.fleetData instanceof EmptyParam) { + this.fleetData = new ArrayList(); + } + ((List) this.fleetData).add(element); + return this; + } + + /** + * Add all elements to `fleetData` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails#fleetData} for the field documentation. + */ + @SuppressWarnings("unchecked") + public Builder addAllFleetData( + List elements) { + if (this.fleetData == null || this.fleetData instanceof EmptyParam) { + this.fleetData = new ArrayList(); + } + ((List) this.fleetData) + .addAll(elements); + return this; + } + + /** Fleet data for this PaymentIntent. */ + public Builder setFleetData(EmptyParam fleetData) { + this.fleetData = fleetData; + return this; + } + + /** Fleet data for this PaymentIntent. */ + public Builder setFleetData( + List fleetData) { + this.fleetData = fleetData; + return this; + } + /** Flight reservation details for this PaymentIntent. */ public Builder setFlight(PaymentIntentConfirmParams.PaymentDetails.Flight flight) { this.flight = flight; @@ -7931,29 +8273,7 @@ public enum Mode implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class Flight { - /** Affiliate details for this purchase. */ - @SerializedName("affiliate") - Affiliate affiliate; - - /** - * The agency number (i.e. International Air Transport Association (IATA) agency number) of - * the travel agency that made the booking. - */ - @SerializedName("agency_number") - String agencyNumber; - - /** - * The International Air Transport Association (IATA) carrier code of the carrier that issued - * the ticket. - */ - @SerializedName("carrier") - String carrier; - - /** Delivery details for this purchase. */ - @SerializedName("delivery") - Delivery delivery; - + public static class FleetData { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -7963,41 +8283,27 @@ public static class Flight { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** The name of the person or entity on the reservation. */ - @SerializedName("passenger_name") - String passengerName; - - /** The details of the passengers in the travel reservation. */ - @SerializedName("passengers") - List passengers; + /** Primary fuel fields for the transaction. */ + @SerializedName("primary_fuel_fields") + PrimaryFuelFields primaryFuelFields; - /** Required. The individual flight segments associated with the trip. */ - @SerializedName("segments") - List segments; + /** Station and acceptor location details. */ + @SerializedName("station") + Station station; - /** The ticket number associated with the travel reservation. */ - @SerializedName("ticket_number") - String ticketNumber; + /** VAT and Invoice on Behalf (IOB) details. */ + @SerializedName("vat") + Vat vat; - private Flight( - Affiliate affiliate, - String agencyNumber, - String carrier, - Delivery delivery, + private FleetData( Map extraParams, - String passengerName, - List passengers, - List segments, - String ticketNumber) { - this.affiliate = affiliate; - this.agencyNumber = agencyNumber; - this.carrier = carrier; - this.delivery = delivery; + PrimaryFuelFields primaryFuelFields, + Station station, + Vat vat) { this.extraParams = extraParams; - this.passengerName = passengerName; - this.passengers = passengers; - this.segments = segments; - this.ticketNumber = ticketNumber; + this.primaryFuelFields = primaryFuelFields; + this.station = station; + this.vat = vat; } public static Builder builder() { @@ -8005,75 +8311,25 @@ public static Builder builder() { } public static class Builder { - private Affiliate affiliate; - - private String agencyNumber; - - private String carrier; - - private Delivery delivery; - private Map extraParams; - private String passengerName; - - private List passengers; + private PrimaryFuelFields primaryFuelFields; - private List segments; + private Station station; - private String ticketNumber; + private Vat vat; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.Flight build() { - return new PaymentIntentConfirmParams.PaymentDetails.Flight( - this.affiliate, - this.agencyNumber, - this.carrier, - this.delivery, - this.extraParams, - this.passengerName, - this.passengers, - this.segments, - this.ticketNumber); - } - - /** Affiliate details for this purchase. */ - public Builder setAffiliate( - PaymentIntentConfirmParams.PaymentDetails.Flight.Affiliate affiliate) { - this.affiliate = affiliate; - return this; + public PaymentIntentConfirmParams.PaymentDetails.FleetData build() { + return new PaymentIntentConfirmParams.PaymentDetails.FleetData( + this.extraParams, this.primaryFuelFields, this.station, this.vat); } /** - * The agency number (i.e. International Air Transport Association (IATA) agency number) of - * the travel agency that made the booking. - */ - public Builder setAgencyNumber(String agencyNumber) { - this.agencyNumber = agencyNumber; - return this; - } - - /** - * The International Air Transport Association (IATA) carrier code of the carrier that - * issued the ticket. - */ - public Builder setCarrier(String carrier) { - this.carrier = carrier; - return this; - } - - /** Delivery details for this purchase. */ - public Builder setDelivery( - PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery delivery) { - this.delivery = delivery; - return this; - } - - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight#extraParams} for the - * field documentation. + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.FleetData#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -8086,7 +8342,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight#extraParams} for the + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.FleetData#extraParams} for the * field documentation. */ public Builder putAllExtraParam(Map map) { @@ -8097,78 +8353,35 @@ public Builder putAllExtraParam(Map map) { return this; } - /** The name of the person or entity on the reservation. */ - public Builder setPassengerName(String passengerName) { - this.passengerName = passengerName; - return this; - } - - /** - * Add an element to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.Flight#passengers} for the field documentation. - */ - public Builder addPassenger( - PaymentIntentConfirmParams.PaymentDetails.Flight.Passenger element) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.add(element); - return this; - } - - /** - * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.Flight#passengers} for the field documentation. - */ - public Builder addAllPassenger( - List elements) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.addAll(elements); - return this; - } - - /** - * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.Flight#segments} for the field documentation. - */ - public Builder addSegment( - PaymentIntentConfirmParams.PaymentDetails.Flight.Segment element) { - if (this.segments == null) { - this.segments = new ArrayList<>(); - } - this.segments.add(element); + /** Primary fuel fields for the transaction. */ + public Builder setPrimaryFuelFields( + PaymentIntentConfirmParams.PaymentDetails.FleetData.PrimaryFuelFields + primaryFuelFields) { + this.primaryFuelFields = primaryFuelFields; return this; } - /** - * Add all elements to `segments` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.Flight#segments} for the field documentation. - */ - public Builder addAllSegment( - List elements) { - if (this.segments == null) { - this.segments = new ArrayList<>(); - } - this.segments.addAll(elements); + /** Station and acceptor location details. */ + public Builder setStation( + PaymentIntentConfirmParams.PaymentDetails.FleetData.Station station) { + this.station = station; return this; } - /** The ticket number associated with the travel reservation. */ - public Builder setTicketNumber(String ticketNumber) { - this.ticketNumber = ticketNumber; + /** VAT and Invoice on Behalf (IOB) details. */ + public Builder setVat(PaymentIntentConfirmParams.PaymentDetails.FleetData.Vat vat) { + this.vat = vat; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Affiliate { + public static class PrimaryFuelFields { + /** The fuel brand. */ + @SerializedName("brand") + Brand brand; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -8179,13 +8392,9 @@ public static class Affiliate { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Required. The name of the affiliate that originated the purchase. */ - @SerializedName("name") - String name; - - private Affiliate(Map extraParams, String name) { + private PrimaryFuelFields(Brand brand, Map extraParams) { + this.brand = brand; this.extraParams = extraParams; - this.name = name; } public static Builder builder() { @@ -8193,21 +8402,29 @@ public static Builder builder() { } public static class Builder { - private Map extraParams; + private Brand brand; - private String name; + private Map extraParams; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.Flight.Affiliate build() { - return new PaymentIntentConfirmParams.PaymentDetails.Flight.Affiliate( - this.extraParams, this.name); + public PaymentIntentConfirmParams.PaymentDetails.FleetData.PrimaryFuelFields build() { + return new PaymentIntentConfirmParams.PaymentDetails.FleetData.PrimaryFuelFields( + this.brand, this.extraParams); + } + + /** The fuel brand. */ + public Builder setBrand( + PaymentIntentConfirmParams.PaymentDetails.FleetData.PrimaryFuelFields.Brand brand) { + this.brand = brand; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight.Affiliate#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FleetData.PrimaryFuelFields#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -8220,8 +8437,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight.Affiliate#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FleetData.PrimaryFuelFields#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -8230,221 +8448,409 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } - - /** Required. The name of the affiliate that originated the purchase. */ - public Builder setName(String name) { - this.name = name; - return this; - } } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Delivery { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public enum Brand implements ApiRequestParams.EnumParam { + @SerializedName("aafes") + AAFES("aafes"), - /** The delivery method for the payment. */ - @SerializedName("mode") - Mode mode; + @SerializedName("amerada_hess") + AMERADA_HESS("amerada_hess"), - /** Details of the recipient. */ - @SerializedName("recipient") - Recipient recipient; + @SerializedName("amoco_canada") + AMOCO_CANADA("amoco_canada"), - private Delivery(Map extraParams, Mode mode, Recipient recipient) { - this.extraParams = extraParams; - this.mode = mode; - this.recipient = recipient; - } + @SerializedName("amoco_petroleum_products") + AMOCO_PETROLEUM_PRODUCTS("amoco_petroleum_products"), - public static Builder builder() { - return new Builder(); - } + @SerializedName("arco_products") + ARCO_PRODUCTS("arco_products"), - public static class Builder { - private Map extraParams; + @SerializedName("asda") + ASDA("asda"), - private Mode mode; + @SerializedName("ashland_oil") + ASHLAND_OIL("ashland_oil"), - private Recipient recipient; + @SerializedName("bfl") + BFL("bfl"), - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery build() { - return new PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery( - this.extraParams, this.mode, this.recipient); - } + @SerializedName("bp_mobil") + BP_MOBIL("bp_mobil"), - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + @SerializedName("bp_oil") + BP_OIL("bp_oil"), - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + @SerializedName("burrnah_major") + BURRNAH_MAJOR("burrnah_major"), - /** The delivery method for the payment. */ - public Builder setMode( - PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery.Mode mode) { - this.mode = mode; - return this; - } + @SerializedName("butler_arndale") + BUTLER_ARNDALE("butler_arndale"), - /** Details of the recipient. */ - public Builder setRecipient( - PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery.Recipient recipient) { - this.recipient = recipient; - return this; - } - } + @SerializedName("canadian_tire") + CANADIAN_TIRE("canadian_tire"), - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Recipient { - /** The email of the recipient the ticket is delivered to. */ - @SerializedName("email") - String email; + @SerializedName("canadian_turbo") + CANADIAN_TURBO("canadian_turbo"), - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + @SerializedName("caseys_general_store") + CASEYS_GENERAL_STORE("caseys_general_store"), - /** The name of the recipient the ticket is delivered to. */ - @SerializedName("name") - String name; + @SerializedName("cenex") + CENEX("cenex"), - /** The phone number of the recipient the ticket is delivered to. */ - @SerializedName("phone") - String phone; + @SerializedName("chevron_canada") + CHEVRON_CANADA("chevron_canada"), - private Recipient( - String email, Map extraParams, String name, String phone) { - this.email = email; - this.extraParams = extraParams; - this.name = name; - this.phone = phone; - } + @SerializedName("chevron_usa") + CHEVRON_USA("chevron_usa"), - public static Builder builder() { - return new Builder(); - } + @SerializedName("circle_k_stores") + CIRCLE_K_STORES("circle_k_stores"), - public static class Builder { - private String email; + @SerializedName("citgo_petroleum") + CITGO_PETROLEUM("citgo_petroleum"), - private Map extraParams; + @SerializedName("clark_brands") + CLARK_BRANDS("clark_brands"), - private String name; + @SerializedName("conoco_canada") + CONOCO_CANADA("conoco_canada"), - private String phone; + @SerializedName("conoco_inc") + CONOCO_INC("conoco_inc"), - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery.Recipient build() { - return new PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery.Recipient( - this.email, this.extraParams, this.name, this.phone); - } + @SerializedName("crown_central_petroleum") + CROWN_CENTRAL_PETROLEUM("crown_central_petroleum"), - /** The email of the recipient the ticket is delivered to. */ - public Builder setEmail(String email) { - this.email = email; - return this; - } + @SerializedName("diamond_shamrock_inc") + DIAMOND_SHAMROCK_INC("diamond_shamrock_inc"), - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + @SerializedName("discount_tire") + DISCOUNT_TIRE("discount_tire"), - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + @SerializedName("domo_gas") + DOMO_GAS("domo_gas"), - /** The name of the recipient the ticket is delivered to. */ - public Builder setName(String name) { - this.name = name; - return this; - } + @SerializedName("elf") + ELF("elf"), - /** The phone number of the recipient the ticket is delivered to. */ - public Builder setPhone(String phone) { - this.phone = phone; - return this; - } - } - } + @SerializedName("erickson_oil") + ERICKSON_OIL("erickson_oil"), - public enum Mode implements ApiRequestParams.EnumParam { - @SerializedName("email") - EMAIL("email"), + @SerializedName("esso") + ESSO("esso"), - @SerializedName("phone") - PHONE("phone"), + @SerializedName("esso_canada") + ESSO_CANADA("esso_canada"), - @SerializedName("pickup") - PICKUP("pickup"), + @SerializedName("exxon") + EXXON("exxon"), - @SerializedName("post") - POST("post"); + @SerializedName("exxonmobil") + EXXONMOBIL("exxonmobil"), + + @SerializedName("family_express") + FAMILY_EXPRESS("family_express"), + + @SerializedName("fas_gas_oil") + FAS_GAS_OIL("fas_gas_oil"), + + @SerializedName("federated_coop_sonic") + FEDERATED_COOP_SONIC("federated_coop_sonic"), + + @SerializedName("fina") + FINA("fina"), + + @SerializedName("fina_inc") + FINA_INC("fina_inc"), + + @SerializedName("fkg_oil") + FKG_OIL("fkg_oil"), + + @SerializedName("flare") + FLARE("flare"), + + @SerializedName("flying_j_inc") + FLYING_J_INC("flying_j_inc"), + + @SerializedName("gas_america") + GAS_AMERICA("gas_america"), + + @SerializedName("gate_petroleum") + GATE_PETROLEUM("gate_petroleum"), + + @SerializedName("getty_petroleum") + GETTY_PETROLEUM("getty_petroleum"), + + @SerializedName("giant_eagle") + GIANT_EAGLE("giant_eagle"), + + @SerializedName("grow_mark_inc") + GROW_MARK_INC("grow_mark_inc"), + + @SerializedName("gulf") + GULF("gulf"), + + @SerializedName("gulf_canada") + GULF_CANADA("gulf_canada"), + + @SerializedName("gulf_chevron") + GULF_CHEVRON("gulf_chevron"), + + @SerializedName("handy_way_food") + HANDY_WAY_FOOD("handy_way_food"), + + @SerializedName("heron") + HERON("heron"), + + @SerializedName("holiday_stores") + HOLIDAY_STORES("holiday_stores"), + + @SerializedName("home_depot") + HOME_DEPOT("home_depot"), + + @SerializedName("husky") + HUSKY("husky"), + + @SerializedName("hyvees") + HYVEES("hyvees"), + + @SerializedName("irving") + IRVING("irving"), + + @SerializedName("irving_oil") + IRVING_OIL("irving_oil"), + + @SerializedName("j_sainsbury") + J_SAINSBURY("j_sainsbury"), + + @SerializedName("jet_conoco") + JET_CONOCO("jet_conoco"), + + @SerializedName("krogers") + KROGERS("krogers"), + + @SerializedName("kuwait") + KUWAIT("kuwait"), + + @SerializedName("kwik_trip_inc") + KWIK_TRIP_INC("kwik_trip_inc"), + + @SerializedName("lassus") + LASSUS("lassus"), + + @SerializedName("loves_country_stores") + LOVES_COUNTRY_STORES("loves_country_stores"), + + @SerializedName("mapco_express_inc") + MAPCO_EXPRESS_INC("mapco_express_inc"), + + @SerializedName("marathon_oil") + MARATHON_OIL("marathon_oil"), + + @SerializedName("martin_bailey_inc_dba_hucks") + MARTIN_BAILEY_INC_DBA_HUCKS("martin_bailey_inc_dba_hucks"), + + @SerializedName("maxol") + MAXOL("maxol"), + + @SerializedName("meineke") + MEINEKE("meineke"), + + @SerializedName("mfa") + MFA("mfa"), + + @SerializedName("mohawk") + MOHAWK("mohawk"), + + @SerializedName("mr_gas") + MR_GAS("mr_gas"), + + @SerializedName("murco") + MURCO("murco"), + + @SerializedName("murphy_oil_canada") + MURPHY_OIL_CANADA("murphy_oil_canada"), + + @SerializedName("murphy_oil_usa_inc") + MURPHY_OIL_USA_INC("murphy_oil_usa_inc"), + + @SerializedName("nexcom") + NEXCOM("nexcom"), + + @SerializedName("nordstrom_oil") + NORDSTROM_OIL("nordstrom_oil"), + + @SerializedName("olco") + OLCO("olco"), + + @SerializedName("pdq_store") + PDQ_STORE("pdq_store"), + + @SerializedName("pennzoil_products_inc") + PENNZOIL_PRODUCTS_INC("pennzoil_products_inc"), + + @SerializedName("petro") + PETRO("petro"), + + @SerializedName("petro_canada") + PETRO_CANADA("petro_canada"), + + @SerializedName("petro_t") + PETRO_T("petro_t"), + + @SerializedName("phillips") + PHILLIPS("phillips"), + + @SerializedName("pilot") + PILOT("pilot"), + + @SerializedName("pioneer") + PIONEER("pioneer"), + + @SerializedName("pure_oil") + PURE_OIL("pure_oil"), + + @SerializedName("quaker_state") + QUAKER_STATE("quaker_state"), + + @SerializedName("quarles_oil") + QUARLES_OIL("quarles_oil"), + + @SerializedName("quiktrip") + QUIKTRIP("quiktrip"), + + @SerializedName("racetrac_petroleum_inc") + RACETRAC_PETROLEUM_INC("racetrac_petroleum_inc"), + + @SerializedName("raceway_petroleum") + RACEWAY_PETROLEUM("raceway_petroleum"), + + @SerializedName("repsol") + REPSOL("repsol"), + + @SerializedName("rudy") + RUDY("rudy"), + + @SerializedName("safeway") + SAFEWAY("safeway"), + + @SerializedName("seven_eleven") + SEVEN_ELEVEN("seven_eleven"), + + @SerializedName("sheetz") + SHEETZ("sheetz"), + + @SerializedName("shell") + SHELL("shell"), + + @SerializedName("shell_canada") + SHELL_CANADA("shell_canada"), + + @SerializedName("shell_oil") + SHELL_OIL("shell_oil"), + + @SerializedName("sinclair_oil") + SINCLAIR_OIL("sinclair_oil"), + + @SerializedName("southland_oil") + SOUTHLAND_OIL("southland_oil"), + + @SerializedName("spar") + SPAR("spar"), + + @SerializedName("speedway") + SPEEDWAY("speedway"), + + @SerializedName("sun_company_inc") + SUN_COMPANY_INC("sun_company_inc"), + + @SerializedName("suncor_sunoco_canada") + SUNCOR_SUNOCO_CANADA("suncor_sunoco_canada"), + + @SerializedName("tempo") + TEMPO("tempo"), + + @SerializedName("tesco") + TESCO("tesco"), + + @SerializedName("tesoro_alaska") + TESORO_ALASKA("tesoro_alaska"), + + @SerializedName("texaco") + TEXACO("texaco"), + + @SerializedName("the_pantry_inc") + THE_PANTRY_INC("the_pantry_inc"), + + @SerializedName("thornton_oil") + THORNTON_OIL("thornton_oil"), + + @SerializedName("tosco") + TOSCO("tosco"), + + @SerializedName("total") + TOTAL("total"), + + @SerializedName("travel_centers_of_america") + TRAVEL_CENTERS_OF_AMERICA("travel_centers_of_america"), + + @SerializedName("uk") + UK("uk"), + + @SerializedName("ultramar_canada") + ULTRAMAR_CANADA("ultramar_canada"), + + @SerializedName("unbranded_or_unassigned") + UNBRANDED_OR_UNASSIGNED("unbranded_or_unassigned"), + + @SerializedName("unbranded_unassigned") + UNBRANDED_UNASSIGNED("unbranded_unassigned"), + + @SerializedName("union_76") + UNION_76("union_76"), + + @SerializedName("united_dairy_farmer") + UNITED_DAIRY_FARMER("united_dairy_farmer"), + + @SerializedName("united_refining_kwikfill") + UNITED_REFINING_KWIKFILL("united_refining_kwikfill"), + + @SerializedName("us_oil") + US_OIL("us_oil"), + + @SerializedName("usa_petroleum") + USA_PETROLEUM("usa_petroleum"), + + @SerializedName("valvoline") + VALVOLINE("valvoline"), + + @SerializedName("vg") + VG("vg"), + + @SerializedName("w_morrison") + W_MORRISON("w_morrison"), + + @SerializedName("warren_equities") + WARREN_EQUITIES("warren_equities"), + + @SerializedName("wawa") + WAWA("wawa"), + + @SerializedName("western_energetix") + WESTERN_ENERGETIX("western_energetix"), + + @SerializedName("wilco") + WILCO("wilco"), + + @SerializedName("zions") + ZIONS("zions"); @Getter(onMethod_ = {@Override}) private final String value; - Mode(String value) { + Brand(String value) { this.value = value; } } @@ -8452,7 +8858,15 @@ public enum Mode implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class Passenger { + public static class Station { + /** Additional contact information for the station. */ + @SerializedName("additional_contact_info") + String additionalContactInfo; + + /** The customer service phone number of the station. */ + @SerializedName("customer_service_phone_number") + String customerServicePhoneNumber; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -8463,15 +8877,37 @@ public static class Passenger { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** - * Required. Full name of the person or entity on the flight reservation. - */ - @SerializedName("name") - String name; + /** The partner ID code of the station. */ + @SerializedName("partner_id_code") + String partnerIdCode; - private Passenger(Map extraParams, String name) { + /** The phone number of the station. */ + @SerializedName("phone_number") + String phoneNumber; + + /** The physical location of the station. */ + @SerializedName("service_location") + ServiceLocation serviceLocation; + + /** The URL of the station. */ + @SerializedName("url") + String url; + + private Station( + String additionalContactInfo, + String customerServicePhoneNumber, + Map extraParams, + String partnerIdCode, + String phoneNumber, + ServiceLocation serviceLocation, + String url) { + this.additionalContactInfo = additionalContactInfo; + this.customerServicePhoneNumber = customerServicePhoneNumber; this.extraParams = extraParams; - this.name = name; + this.partnerIdCode = partnerIdCode; + this.phoneNumber = phoneNumber; + this.serviceLocation = serviceLocation; + this.url = url; } public static Builder builder() { @@ -8479,21 +8915,50 @@ public static Builder builder() { } public static class Builder { + private String additionalContactInfo; + + private String customerServicePhoneNumber; + private Map extraParams; - private String name; + private String partnerIdCode; + + private String phoneNumber; + + private ServiceLocation serviceLocation; + + private String url; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.Flight.Passenger build() { - return new PaymentIntentConfirmParams.PaymentDetails.Flight.Passenger( - this.extraParams, this.name); + public PaymentIntentConfirmParams.PaymentDetails.FleetData.Station build() { + return new PaymentIntentConfirmParams.PaymentDetails.FleetData.Station( + this.additionalContactInfo, + this.customerServicePhoneNumber, + this.extraParams, + this.partnerIdCode, + this.phoneNumber, + this.serviceLocation, + this.url); + } + + /** Additional contact information for the station. */ + public Builder setAdditionalContactInfo(String additionalContactInfo) { + this.additionalContactInfo = additionalContactInfo; + return this; + } + + /** The customer service phone number of the station. */ + public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight.Passenger#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FleetData.Station#extraParams} for the field + * documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -8506,8 +8971,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight.Passenger#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FleetData.Station#extraParams} for the field + * documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -8517,182 +8983,250 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Required. Full name of the person or entity on the flight reservation. - */ - public Builder setName(String name) { - this.name = name; + /** The partner ID code of the station. */ + public Builder setPartnerIdCode(String partnerIdCode) { + this.partnerIdCode = partnerIdCode; return this; } - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Segment { - /** The flight segment amount. */ - @SerializedName("amount") - Long amount; - /** - * The International Air Transport Association (IATA) airport code for the arrival airport. - */ - @SerializedName("arrival_airport") - String arrivalAirport; + /** The phone number of the station. */ + public Builder setPhoneNumber(String phoneNumber) { + this.phoneNumber = phoneNumber; + return this; + } - /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ - @SerializedName("arrives_at") - Long arrivesAt; + /** The physical location of the station. */ + public Builder setServiceLocation( + PaymentIntentConfirmParams.PaymentDetails.FleetData.Station.ServiceLocation + serviceLocation) { + this.serviceLocation = serviceLocation; + return this; + } - /** - * The International Air Transport Association (IATA) carrier code of the carrier operating - * the flight segment. - */ - @SerializedName("carrier") - String carrier; + /** The URL of the station. */ + public Builder setUrl(String url) { + this.url = url; + return this; + } + } - /** - * Required. The departure time for the flight segment. Measured in seconds - * since the Unix epoch. - */ - @SerializedName("departs_at") - Long departsAt; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ServiceLocation { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + String city; - /** - * The International Air Transport Association (IATA) airport code for the departure - * airport. - */ - @SerializedName("departure_airport") - String departureAirport; + /** + * Two-letter country code (ISO + * 3166-1 alpha-2). + */ + @SerializedName("country") + String country; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** The flight number associated with the segment. */ - @SerializedName("flight_number") - String flightNumber; + /** + * Required. Address line 1, such as the street, PO Box, or company name. + */ + @SerializedName("line1") + String line1; - /** The fare class for the segment. */ - @SerializedName("service_class") - ServiceClass serviceClass; + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; - private Segment( - Long amount, - String arrivalAirport, - Long arrivesAt, - String carrier, - Long departsAt, - String departureAirport, - Map extraParams, - String flightNumber, - ServiceClass serviceClass) { - this.amount = amount; - this.arrivalAirport = arrivalAirport; - this.arrivesAt = arrivesAt; - this.carrier = carrier; - this.departsAt = departsAt; - this.departureAirport = departureAirport; - this.extraParams = extraParams; - this.flightNumber = flightNumber; - this.serviceClass = serviceClass; - } + /** ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; - public static Builder builder() { - return new Builder(); - } + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; - public static class Builder { - private Long amount; + private ServiceLocation( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } - private String arrivalAirport; + public static Builder builder() { + return new Builder(); + } - private Long arrivesAt; + public static class Builder { + private String city; - private String carrier; + private String country; - private Long departsAt; + private Map extraParams; - private String departureAirport; + private String line1; - private Map extraParams; + private String line2; - private String flightNumber; + private String postalCode; - private ServiceClass serviceClass; + private String state; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.Flight.Segment build() { - return new PaymentIntentConfirmParams.PaymentDetails.Flight.Segment( - this.amount, - this.arrivalAirport, - this.arrivesAt, - this.carrier, - this.departsAt, - this.departureAirport, - this.extraParams, - this.flightNumber, - this.serviceClass); - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.FleetData.Station.ServiceLocation + build() { + return new PaymentIntentConfirmParams.PaymentDetails.FleetData.Station + .ServiceLocation( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } - /** The flight segment amount. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } - /** - * The International Air Transport Association (IATA) airport code for the arrival - * airport. - */ - public Builder setArrivalAirport(String arrivalAirport) { - this.arrivalAirport = arrivalAirport; - return this; - } + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } - /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ - public Builder setArrivesAt(Long arrivesAt) { - this.arrivesAt = arrivesAt; - return this; - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FleetData.Station.ServiceLocation#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** - * The International Air Transport Association (IATA) carrier code of the carrier - * operating the flight segment. - */ - public Builder setCarrier(String carrier) { - this.carrier = carrier; - return this; - } + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FleetData.Station.ServiceLocation#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** - * Required. The departure time for the flight segment. Measured in - * seconds since the Unix epoch. - */ - public Builder setDepartsAt(Long departsAt) { - this.departsAt = departsAt; - return this; + /** + * Required. Address line 1, such as the street, PO Box, or company + * name. + */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } + + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } + + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } + + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } } + } + } - /** - * The International Air Transport Association (IATA) airport code for the departure - * airport. - */ - public Builder setDepartureAirport(String departureAirport) { - this.departureAirport = departureAirport; - return this; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Vat { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** + * Required. Indicates the merchant's agreement for Invoice on Behalf (IOB) + * VAT processing. + */ + @SerializedName("iob_indicator") + IobIndicator iobIndicator; + + private Vat(Map extraParams, IobIndicator iobIndicator) { + this.extraParams = extraParams; + this.iobIndicator = iobIndicator; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private IobIndicator iobIndicator; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.FleetData.Vat build() { + return new PaymentIntentConfirmParams.PaymentDetails.FleetData.Vat( + this.extraParams, this.iobIndicator); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight.Segment#extraParams} + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.FleetData.Vat#extraParams} * for the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -8706,7 +9240,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight.Segment#extraParams} + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.FleetData.Vat#extraParams} * for the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -8717,37 +9251,32 @@ public Builder putAllExtraParam(Map map) { return this; } - /** The flight number associated with the segment. */ - public Builder setFlightNumber(String flightNumber) { - this.flightNumber = flightNumber; - return this; - } - - /** The fare class for the segment. */ - public Builder setServiceClass( - PaymentIntentConfirmParams.PaymentDetails.Flight.Segment.ServiceClass serviceClass) { - this.serviceClass = serviceClass; + /** + * Required. Indicates the merchant's agreement for Invoice on Behalf + * (IOB) VAT processing. + */ + public Builder setIobIndicator( + PaymentIntentConfirmParams.PaymentDetails.FleetData.Vat.IobIndicator iobIndicator) { + this.iobIndicator = iobIndicator; return this; } } - public enum ServiceClass implements ApiRequestParams.EnumParam { - @SerializedName("business") - BUSINESS("business"), + public enum IobIndicator implements ApiRequestParams.EnumParam { + @SerializedName("issuer_to_iob") + ISSUER_TO_IOB("issuer_to_iob"), - @SerializedName("economy") - ECONOMY("economy"), + @SerializedName("issuer_to_iob_and_incremental_certification") + ISSUER_TO_IOB_AND_INCREMENTAL_CERTIFICATION( + "issuer_to_iob_and_incremental_certification"), - @SerializedName("first") - FIRST("first"), - - @SerializedName("premium_economy") - PREMIUM_ECONOMY("premium_economy"); + @SerializedName("merchant_does_not_agree_to_iob") + MERCHANT_DOES_NOT_AGREE_TO_IOB("merchant_does_not_agree_to_iob"); @Getter(onMethod_ = {@Override}) private final String value; - ServiceClass(String value) { + IobIndicator(String value) { this.value = value; } } @@ -8756,22 +9285,28 @@ public enum ServiceClass implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class FlightData { - /** Affiliate details if applicable. */ + public static class Flight { + /** Affiliate details for this purchase. */ @SerializedName("affiliate") Affiliate affiliate; - /** Reservation reference. */ - @SerializedName("booking_number") - String bookingNumber; + /** + * The agency number (i.e. International Air Transport Association (IATA) agency number) of + * the travel agency that made the booking. + */ + @SerializedName("agency_number") + String agencyNumber; - /** Computerized reservation system used to make the reservation and purchase the ticket. */ - @SerializedName("computerized_reservation_system") - String computerizedReservationSystem; + /** + * The International Air Transport Association (IATA) carrier code of the carrier that issued + * the ticket. + */ + @SerializedName("carrier") + String carrier; - /** Ticket restrictions. */ - @SerializedName("endorsements_and_restrictions") - String endorsementsAndRestrictions; + /** Delivery details for this purchase. */ + @SerializedName("delivery") + Delivery delivery; /** * Map of extra parameters for custom features not available in this client library. The @@ -8782,53 +9317,41 @@ public static class FlightData { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** List of insurances. */ - @SerializedName("insurances") - List insurances; + /** The name of the person or entity on the reservation. */ + @SerializedName("passenger_name") + String passengerName; - /** List of passengers. */ + /** The details of the passengers in the travel reservation. */ @SerializedName("passengers") - List passengers; + List passengers; - /** Required. List of flight segments. */ + /** Required. The individual flight segments associated with the trip. */ @SerializedName("segments") - List segments; - - /** Electronic ticket indicator. */ - @SerializedName("ticket_electronically_issued_indicator") - Boolean ticketElectronicallyIssuedIndicator; - - /** Required. Total cost breakdown. */ - @SerializedName("total") - Total total; + List segments; - /** Type of flight transaction. */ - @SerializedName("transaction_type") - TransactionType transactionType; + /** The ticket number associated with the travel reservation. */ + @SerializedName("ticket_number") + String ticketNumber; - private FlightData( + private Flight( Affiliate affiliate, - String bookingNumber, - String computerizedReservationSystem, - String endorsementsAndRestrictions, + String agencyNumber, + String carrier, + Delivery delivery, Map extraParams, - List insurances, - List passengers, - List segments, - Boolean ticketElectronicallyIssuedIndicator, - Total total, - TransactionType transactionType) { + String passengerName, + List passengers, + List segments, + String ticketNumber) { this.affiliate = affiliate; - this.bookingNumber = bookingNumber; - this.computerizedReservationSystem = computerizedReservationSystem; - this.endorsementsAndRestrictions = endorsementsAndRestrictions; + this.agencyNumber = agencyNumber; + this.carrier = carrier; + this.delivery = delivery; this.extraParams = extraParams; - this.insurances = insurances; + this.passengerName = passengerName; this.passengers = passengers; this.segments = segments; - this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; - this.total = total; - this.transactionType = transactionType; + this.ticketNumber = ticketNumber; } public static Builder builder() { @@ -8838,71 +9361,72 @@ public static Builder builder() { public static class Builder { private Affiliate affiliate; - private String bookingNumber; + private String agencyNumber; - private String computerizedReservationSystem; + private String carrier; - private String endorsementsAndRestrictions; + private Delivery delivery; private Map extraParams; - private List insurances; - - private List passengers; - - private List segments; + private String passengerName; - private Boolean ticketElectronicallyIssuedIndicator; + private List passengers; - private Total total; + private List segments; - private TransactionType transactionType; + private String ticketNumber; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.FlightData build() { - return new PaymentIntentConfirmParams.PaymentDetails.FlightData( + public PaymentIntentConfirmParams.PaymentDetails.Flight build() { + return new PaymentIntentConfirmParams.PaymentDetails.Flight( this.affiliate, - this.bookingNumber, - this.computerizedReservationSystem, - this.endorsementsAndRestrictions, + this.agencyNumber, + this.carrier, + this.delivery, this.extraParams, - this.insurances, + this.passengerName, this.passengers, this.segments, - this.ticketElectronicallyIssuedIndicator, - this.total, - this.transactionType); + this.ticketNumber); } - /** Affiliate details if applicable. */ + /** Affiliate details for this purchase. */ public Builder setAffiliate( - PaymentIntentConfirmParams.PaymentDetails.FlightData.Affiliate affiliate) { + PaymentIntentConfirmParams.PaymentDetails.Flight.Affiliate affiliate) { this.affiliate = affiliate; return this; } - /** Reservation reference. */ - public Builder setBookingNumber(String bookingNumber) { - this.bookingNumber = bookingNumber; + /** + * The agency number (i.e. International Air Transport Association (IATA) agency number) of + * the travel agency that made the booking. + */ + public Builder setAgencyNumber(String agencyNumber) { + this.agencyNumber = agencyNumber; return this; } - /** Computerized reservation system used to make the reservation and purchase the ticket. */ - public Builder setComputerizedReservationSystem(String computerizedReservationSystem) { - this.computerizedReservationSystem = computerizedReservationSystem; + /** + * The International Air Transport Association (IATA) carrier code of the carrier that + * issued the ticket. + */ + public Builder setCarrier(String carrier) { + this.carrier = carrier; return this; } - /** Ticket restrictions. */ - public Builder setEndorsementsAndRestrictions(String endorsementsAndRestrictions) { - this.endorsementsAndRestrictions = endorsementsAndRestrictions; + /** Delivery details for this purchase. */ + public Builder setDelivery( + PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery delivery) { + this.delivery = delivery; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.FlightData#extraParams} for the + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight#extraParams} for the * field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -8916,7 +9440,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.FlightData#extraParams} for the + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight#extraParams} for the * field documentation. */ public Builder putAllExtraParam(Map map) { @@ -8927,44 +9451,19 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Add an element to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData#insurances} for the field - * documentation. - */ - public Builder addInsurance( - PaymentIntentConfirmParams.PaymentDetails.FlightData.Insurance element) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); - } - this.insurances.add(element); - return this; - } - - /** - * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData#insurances} for the field - * documentation. - */ - public Builder addAllInsurance( - List elements) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); - } - this.insurances.addAll(elements); + /** The name of the person or entity on the reservation. */ + public Builder setPassengerName(String passengerName) { + this.passengerName = passengerName; return this; } /** * Add an element to `passengers` list. A list is initialized for the first `add/addAll` * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData#passengers} for the field - * documentation. + * PaymentIntentConfirmParams.PaymentDetails.Flight#passengers} for the field documentation. */ public Builder addPassenger( - PaymentIntentConfirmParams.PaymentDetails.FlightData.Passenger element) { + PaymentIntentConfirmParams.PaymentDetails.Flight.Passenger element) { if (this.passengers == null) { this.passengers = new ArrayList<>(); } @@ -8975,11 +9474,10 @@ public Builder addPassenger( /** * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData#passengers} for the field - * documentation. + * PaymentIntentConfirmParams.PaymentDetails.Flight#passengers} for the field documentation. */ public Builder addAllPassenger( - List elements) { + List elements) { if (this.passengers == null) { this.passengers = new ArrayList<>(); } @@ -8990,11 +9488,10 @@ public Builder addAllPassenger( /** * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, * and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData#segments} for the field - * documentation. + * PaymentIntentConfirmParams.PaymentDetails.Flight#segments} for the field documentation. */ public Builder addSegment( - PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment element) { + PaymentIntentConfirmParams.PaymentDetails.Flight.Segment element) { if (this.segments == null) { this.segments = new ArrayList<>(); } @@ -9005,11 +9502,10 @@ public Builder addSegment( /** * Add all elements to `segments` list. A list is initialized for the first `add/addAll` * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData#segments} for the field - * documentation. + * PaymentIntentConfirmParams.PaymentDetails.Flight#segments} for the field documentation. */ public Builder addAllSegment( - List elements) { + List elements) { if (this.segments == null) { this.segments = new ArrayList<>(); } @@ -9017,23 +9513,9 @@ public Builder addAllSegment( return this; } - /** Electronic ticket indicator. */ - public Builder setTicketElectronicallyIssuedIndicator( - Boolean ticketElectronicallyIssuedIndicator) { - this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; - return this; - } - - /** Required. Total cost breakdown. */ - public Builder setTotal(PaymentIntentConfirmParams.PaymentDetails.FlightData.Total total) { - this.total = total; - return this; - } - - /** Type of flight transaction. */ - public Builder setTransactionType( - PaymentIntentConfirmParams.PaymentDetails.FlightData.TransactionType transactionType) { - this.transactionType = transactionType; + /** The ticket number associated with the travel reservation. */ + public Builder setTicketNumber(String ticketNumber) { + this.ticketNumber = ticketNumber; return this; } } @@ -9041,10 +9523,6 @@ public Builder setTransactionType( @Getter @EqualsAndHashCode(callSuper = false) public static class Affiliate { - /** Affiliate partner code. */ - @SerializedName("code") - String code; - /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -9055,23 +9533,13 @@ public static class Affiliate { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Name of affiliate partner. */ + /** Required. The name of the affiliate that originated the purchase. */ @SerializedName("name") String name; - /** Code provided by the company to a travel agent authorizing ticket issuance. */ - @SerializedName("travel_authorization_code") - String travelAuthorizationCode; - - private Affiliate( - String code, - Map extraParams, - String name, - String travelAuthorizationCode) { - this.code = code; + private Affiliate(Map extraParams, String name) { this.extraParams = extraParams; this.name = name; - this.travelAuthorizationCode = travelAuthorizationCode; } public static Builder builder() { @@ -9079,32 +9547,21 @@ public static Builder builder() { } public static class Builder { - private String code; - private Map extraParams; private String name; - private String travelAuthorizationCode; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.FlightData.Affiliate build() { - return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Affiliate( - this.code, this.extraParams, this.name, this.travelAuthorizationCode); - } - - /** Affiliate partner code. */ - public Builder setCode(String code) { - this.code = code; - return this; + public PaymentIntentConfirmParams.PaymentDetails.Flight.Affiliate build() { + return new PaymentIntentConfirmParams.PaymentDetails.Flight.Affiliate( + this.extraParams, this.name); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Affiliate#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight.Affiliate#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -9117,9 +9574,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Affiliate#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight.Affiliate#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -9129,31 +9585,17 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Name of affiliate partner. */ + /** Required. The name of the affiliate that originated the purchase. */ public Builder setName(String name) { this.name = name; return this; } - - /** Code provided by the company to a travel agent authorizing ticket issuance. */ - public Builder setTravelAuthorizationCode(String travelAuthorizationCode) { - this.travelAuthorizationCode = travelAuthorizationCode; - return this; - } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Insurance { - /** Required. Insurance cost. */ - @SerializedName("amount") - Long amount; - - /** Insurance currency. */ - @SerializedName("currency") - String currency; - + public static class Delivery { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -9164,25 +9606,18 @@ public static class Insurance { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Insurance company name. */ - @SerializedName("insurance_company_name") - String insuranceCompanyName; + /** The delivery method for the payment. */ + @SerializedName("mode") + Mode mode; - /** Required. Type of insurance. */ - @SerializedName("insurance_type") - InsuranceType insuranceType; + /** Details of the recipient. */ + @SerializedName("recipient") + Recipient recipient; - private Insurance( - Long amount, - String currency, - Map extraParams, - String insuranceCompanyName, - InsuranceType insuranceType) { - this.amount = amount; - this.currency = currency; + private Delivery(Map extraParams, Mode mode, Recipient recipient) { this.extraParams = extraParams; - this.insuranceCompanyName = insuranceCompanyName; - this.insuranceType = insuranceType; + this.mode = mode; + this.recipient = recipient; } public static Builder builder() { @@ -9190,44 +9625,23 @@ public static Builder builder() { } public static class Builder { - private Long amount; - - private String currency; - private Map extraParams; - private String insuranceCompanyName; + private Mode mode; - private InsuranceType insuranceType; + private Recipient recipient; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.FlightData.Insurance build() { - return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Insurance( - this.amount, - this.currency, - this.extraParams, - this.insuranceCompanyName, - this.insuranceType); - } - - /** Required. Insurance cost. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } - - /** Insurance currency. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; + public PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery build() { + return new PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery( + this.extraParams, this.mode, this.recipient); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Insurance#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -9240,9 +9654,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Insurance#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -9252,41 +9665,140 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Insurance company name. */ - public Builder setInsuranceCompanyName(String insuranceCompanyName) { - this.insuranceCompanyName = insuranceCompanyName; + /** The delivery method for the payment. */ + public Builder setMode( + PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery.Mode mode) { + this.mode = mode; return this; } - /** Required. Type of insurance. */ - public Builder setInsuranceType( - PaymentIntentConfirmParams.PaymentDetails.FlightData.Insurance.InsuranceType - insuranceType) { - this.insuranceType = insuranceType; + /** Details of the recipient. */ + public Builder setRecipient( + PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery.Recipient recipient) { + this.recipient = recipient; return this; } } - public enum InsuranceType implements ApiRequestParams.EnumParam { - @SerializedName("baggage") - BAGGAGE("baggage"), + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Recipient { + /** The email of the recipient the ticket is delivered to. */ + @SerializedName("email") + String email; - @SerializedName("bankruptcy") - BANKRUPTCY("bankruptcy"), + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - @SerializedName("cancelation") - CANCELATION("cancelation"), + /** The name of the recipient the ticket is delivered to. */ + @SerializedName("name") + String name; - @SerializedName("emergency") - EMERGENCY("emergency"), + /** The phone number of the recipient the ticket is delivered to. */ + @SerializedName("phone") + String phone; - @SerializedName("medical") - MEDICAL("medical"); + private Recipient( + String email, Map extraParams, String name, String phone) { + this.email = email; + this.extraParams = extraParams; + this.name = name; + this.phone = phone; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String email; + + private Map extraParams; + + private String name; + + private String phone; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery.Recipient build() { + return new PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery.Recipient( + this.email, this.extraParams, this.name, this.phone); + } + + /** The email of the recipient the ticket is delivered to. */ + public Builder setEmail(String email) { + this.email = email; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The name of the recipient the ticket is delivered to. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** The phone number of the recipient the ticket is delivered to. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } + } + } + + public enum Mode implements ApiRequestParams.EnumParam { + @SerializedName("email") + EMAIL("email"), + + @SerializedName("phone") + PHONE("phone"), + + @SerializedName("pickup") + PICKUP("pickup"), + + @SerializedName("post") + POST("post"); @Getter(onMethod_ = {@Override}) private final String value; - InsuranceType(String value) { + Mode(String value) { this.value = value; } } @@ -9305,7 +9817,9 @@ public static class Passenger { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Required. Passenger's full name. */ + /** + * Required. Full name of the person or entity on the flight reservation. + */ @SerializedName("name") String name; @@ -9324,17 +9838,16 @@ public static class Builder { private String name; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.FlightData.Passenger build() { - return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Passenger( + public PaymentIntentConfirmParams.PaymentDetails.Flight.Passenger build() { + return new PaymentIntentConfirmParams.PaymentDetails.Flight.Passenger( this.extraParams, this.name); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Passenger#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight.Passenger#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -9347,9 +9860,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Passenger#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight.Passenger#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -9359,9 +9871,11 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Required. Passenger's full name. */ - public Builder setName(String name) { - this.name = name; + /** + * Required. Full name of the person or entity on the flight reservation. + */ + public Builder setName(String name) { + this.name = name; return this; } } @@ -9370,33 +9884,40 @@ public Builder setName(String name) { @Getter @EqualsAndHashCode(callSuper = false) public static class Segment { - /** Segment fare amount. */ + /** The flight segment amount. */ @SerializedName("amount") Long amount; - /** Required. Arrival details. */ - @SerializedName("arrival") - Arrival arrival; - - /** Required. Airline carrier code. */ - @SerializedName("carrier_code") - String carrierCode; + /** + * The International Air Transport Association (IATA) airport code for the arrival airport. + */ + @SerializedName("arrival_airport") + String arrivalAirport; - /** Carrier name. */ - @SerializedName("carrier_name") - String carrierName; + /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ + @SerializedName("arrives_at") + Long arrivesAt; - /** Segment currency. */ - @SerializedName("currency") - String currency; + /** + * The International Air Transport Association (IATA) carrier code of the carrier operating + * the flight segment. + */ + @SerializedName("carrier") + String carrier; - /** Required. Departure details. */ - @SerializedName("departure") - Departure departure; + /** + * Required. The departure time for the flight segment. Measured in seconds + * since the Unix epoch. + */ + @SerializedName("departs_at") + Long departsAt; - /** Exchange ticket number. */ - @SerializedName("exchange_ticket_number") - String exchangeTicketNumber; + /** + * The International Air Transport Association (IATA) airport code for the departure + * airport. + */ + @SerializedName("departure_airport") + String departureAirport; /** * Map of extra parameters for custom features not available in this client library. The @@ -9408,71 +9929,33 @@ public static class Segment { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Fare basis code. */ - @SerializedName("fare_basis_code") - String fareBasisCode; - - /** Additional fees. */ - @SerializedName("fees") - Long fees; - - /** Flight number. */ + /** The flight number associated with the segment. */ @SerializedName("flight_number") String flightNumber; - /** Stopover indicator. */ - @SerializedName("is_stop_over_indicator") - Boolean isStopOverIndicator; - - /** Refundable ticket indicator. */ - @SerializedName("refundable") - Boolean refundable; - - /** Required. Class of service. */ + /** The fare class for the segment. */ @SerializedName("service_class") ServiceClass serviceClass; - /** Tax amount for segment. */ - @SerializedName("tax_amount") - Long taxAmount; - - /** Ticket number. */ - @SerializedName("ticket_number") - String ticketNumber; - private Segment( Long amount, - Arrival arrival, - String carrierCode, - String carrierName, - String currency, - Departure departure, - String exchangeTicketNumber, + String arrivalAirport, + Long arrivesAt, + String carrier, + Long departsAt, + String departureAirport, Map extraParams, - String fareBasisCode, - Long fees, String flightNumber, - Boolean isStopOverIndicator, - Boolean refundable, - ServiceClass serviceClass, - Long taxAmount, - String ticketNumber) { + ServiceClass serviceClass) { this.amount = amount; - this.arrival = arrival; - this.carrierCode = carrierCode; - this.carrierName = carrierName; - this.currency = currency; - this.departure = departure; - this.exchangeTicketNumber = exchangeTicketNumber; + this.arrivalAirport = arrivalAirport; + this.arrivesAt = arrivesAt; + this.carrier = carrier; + this.departsAt = departsAt; + this.departureAirport = departureAirport; this.extraParams = extraParams; - this.fareBasisCode = fareBasisCode; - this.fees = fees; this.flightNumber = flightNumber; - this.isStopOverIndicator = isStopOverIndicator; - this.refundable = refundable; this.serviceClass = serviceClass; - this.taxAmount = taxAmount; - this.ticketNumber = ticketNumber; } public static Builder builder() { @@ -9482,107 +9965,89 @@ public static Builder builder() { public static class Builder { private Long amount; - private Arrival arrival; - - private String carrierCode; + private String arrivalAirport; - private String carrierName; + private Long arrivesAt; - private String currency; + private String carrier; - private Departure departure; + private Long departsAt; - private String exchangeTicketNumber; + private String departureAirport; private Map extraParams; - private String fareBasisCode; - - private Long fees; - private String flightNumber; - private Boolean isStopOverIndicator; - - private Boolean refundable; - private ServiceClass serviceClass; - private Long taxAmount; - - private String ticketNumber; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment build() { - return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment( + public PaymentIntentConfirmParams.PaymentDetails.Flight.Segment build() { + return new PaymentIntentConfirmParams.PaymentDetails.Flight.Segment( this.amount, - this.arrival, - this.carrierCode, - this.carrierName, - this.currency, - this.departure, - this.exchangeTicketNumber, + this.arrivalAirport, + this.arrivesAt, + this.carrier, + this.departsAt, + this.departureAirport, this.extraParams, - this.fareBasisCode, - this.fees, this.flightNumber, - this.isStopOverIndicator, - this.refundable, - this.serviceClass, - this.taxAmount, - this.ticketNumber); + this.serviceClass); } - /** Segment fare amount. */ + /** The flight segment amount. */ public Builder setAmount(Long amount) { this.amount = amount; return this; } - /** Required. Arrival details. */ - public Builder setArrival( - PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Arrival arrival) { - this.arrival = arrival; - return this; - } - - /** Required. Airline carrier code. */ - public Builder setCarrierCode(String carrierCode) { - this.carrierCode = carrierCode; + /** + * The International Air Transport Association (IATA) airport code for the arrival + * airport. + */ + public Builder setArrivalAirport(String arrivalAirport) { + this.arrivalAirport = arrivalAirport; return this; } - /** Carrier name. */ - public Builder setCarrierName(String carrierName) { - this.carrierName = carrierName; + /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ + public Builder setArrivesAt(Long arrivesAt) { + this.arrivesAt = arrivesAt; return this; } - /** Segment currency. */ - public Builder setCurrency(String currency) { - this.currency = currency; + /** + * The International Air Transport Association (IATA) carrier code of the carrier + * operating the flight segment. + */ + public Builder setCarrier(String carrier) { + this.carrier = carrier; return this; } - /** Required. Departure details. */ - public Builder setDeparture( - PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Departure departure) { - this.departure = departure; + /** + * Required. The departure time for the flight segment. Measured in + * seconds since the Unix epoch. + */ + public Builder setDepartsAt(Long departsAt) { + this.departsAt = departsAt; return this; } - /** Exchange ticket number. */ - public Builder setExchangeTicketNumber(String exchangeTicketNumber) { - this.exchangeTicketNumber = exchangeTicketNumber; + /** + * The International Air Transport Association (IATA) airport code for the departure + * airport. + */ + public Builder setDepartureAirport(String departureAirport) { + this.departureAirport = departureAirport; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment#extraParams} for the field - * documentation. + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight.Segment#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -9595,9 +10060,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment#extraParams} for the field - * documentation. + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Flight.Segment#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -9607,339 +10071,333 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Fare basis code. */ - public Builder setFareBasisCode(String fareBasisCode) { - this.fareBasisCode = fareBasisCode; - return this; - } - - /** Additional fees. */ - public Builder setFees(Long fees) { - this.fees = fees; - return this; - } - - /** Flight number. */ + /** The flight number associated with the segment. */ public Builder setFlightNumber(String flightNumber) { this.flightNumber = flightNumber; return this; } - /** Stopover indicator. */ - public Builder setIsStopOverIndicator(Boolean isStopOverIndicator) { - this.isStopOverIndicator = isStopOverIndicator; - return this; - } - - /** Refundable ticket indicator. */ - public Builder setRefundable(Boolean refundable) { - this.refundable = refundable; - return this; - } - - /** Required. Class of service. */ + /** The fare class for the segment. */ public Builder setServiceClass( - PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.ServiceClass - serviceClass) { + PaymentIntentConfirmParams.PaymentDetails.Flight.Segment.ServiceClass serviceClass) { this.serviceClass = serviceClass; return this; } - - /** Tax amount for segment. */ - public Builder setTaxAmount(Long taxAmount) { - this.taxAmount = taxAmount; - return this; - } - - /** Ticket number. */ - public Builder setTicketNumber(String ticketNumber) { - this.ticketNumber = ticketNumber; - return this; - } } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Arrival { - /** Required. Arrival airport IATA code. */ - @SerializedName("airport") - String airport; - - /** Arrival date/time. */ - @SerializedName("arrives_at") - Long arrivesAt; + public enum ServiceClass implements ApiRequestParams.EnumParam { + @SerializedName("business") + BUSINESS("business"), - /** Arrival city. */ - @SerializedName("city") - String city; + @SerializedName("economy") + ECONOMY("economy"), - /** Arrival country. */ - @SerializedName("country") - String country; + @SerializedName("first") + FIRST("first"), - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + @SerializedName("premium_economy") + PREMIUM_ECONOMY("premium_economy"); - private Arrival( - String airport, - Long arrivesAt, - String city, - String country, - Map extraParams) { - this.airport = airport; - this.arrivesAt = arrivesAt; - this.city = city; - this.country = country; - this.extraParams = extraParams; - } + @Getter(onMethod_ = {@Override}) + private final String value; - public static Builder builder() { - return new Builder(); + ServiceClass(String value) { + this.value = value; } + } + } + } - public static class Builder { - private String airport; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class FlightData { + /** Affiliate details if applicable. */ + @SerializedName("affiliate") + Affiliate affiliate; - private Long arrivesAt; + /** Reservation reference. */ + @SerializedName("booking_number") + String bookingNumber; - private String city; + /** Computerized reservation system used to make the reservation and purchase the ticket. */ + @SerializedName("computerized_reservation_system") + String computerizedReservationSystem; - private String country; + /** Ticket restrictions. */ + @SerializedName("endorsements_and_restrictions") + String endorsementsAndRestrictions; - private Map extraParams; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Arrival build() { - return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Arrival( - this.airport, this.arrivesAt, this.city, this.country, this.extraParams); - } + /** List of insurances. */ + @SerializedName("insurances") + List insurances; - /** Required. Arrival airport IATA code. */ - public Builder setAirport(String airport) { - this.airport = airport; - return this; - } + /** List of passengers. */ + @SerializedName("passengers") + List passengers; - /** Arrival date/time. */ - public Builder setArrivesAt(Long arrivesAt) { - this.arrivesAt = arrivesAt; - return this; - } + /** Required. List of flight segments. */ + @SerializedName("segments") + List segments; - /** Arrival city. */ - public Builder setCity(String city) { - this.city = city; - return this; - } + /** Electronic ticket indicator. */ + @SerializedName("ticket_electronically_issued_indicator") + Boolean ticketElectronicallyIssuedIndicator; - /** Arrival country. */ - public Builder setCountry(String country) { - this.country = country; - return this; - } + /** Required. Total cost breakdown. */ + @SerializedName("total") + Total total; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Arrival#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Type of flight transaction. */ + @SerializedName("transaction_type") + TransactionType transactionType; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Arrival#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } - } - } + private FlightData( + Affiliate affiliate, + String bookingNumber, + String computerizedReservationSystem, + String endorsementsAndRestrictions, + Map extraParams, + List insurances, + List passengers, + List segments, + Boolean ticketElectronicallyIssuedIndicator, + Total total, + TransactionType transactionType) { + this.affiliate = affiliate; + this.bookingNumber = bookingNumber; + this.computerizedReservationSystem = computerizedReservationSystem; + this.endorsementsAndRestrictions = endorsementsAndRestrictions; + this.extraParams = extraParams; + this.insurances = insurances; + this.passengers = passengers; + this.segments = segments; + this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; + this.total = total; + this.transactionType = transactionType; + } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Departure { - /** Required. Departure airport IATA code. */ - @SerializedName("airport") - String airport; + public static Builder builder() { + return new Builder(); + } - /** Departure city. */ - @SerializedName("city") - String city; + public static class Builder { + private Affiliate affiliate; - /** Departure country. */ - @SerializedName("country") - String country; + private String bookingNumber; - /** Required. Departure date/time. */ - @SerializedName("departs_at") - Long departsAt; + private String computerizedReservationSystem; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private String endorsementsAndRestrictions; - private Departure( - String airport, - String city, - String country, - Long departsAt, - Map extraParams) { - this.airport = airport; - this.city = city; - this.country = country; - this.departsAt = departsAt; - this.extraParams = extraParams; - } + private Map extraParams; - public static Builder builder() { - return new Builder(); - } + private List insurances; - public static class Builder { - private String airport; + private List passengers; - private String city; + private List segments; - private String country; + private Boolean ticketElectronicallyIssuedIndicator; - private Long departsAt; + private Total total; - private Map extraParams; + private TransactionType transactionType; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Departure build() { - return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Departure( - this.airport, this.city, this.country, this.departsAt, this.extraParams); - } - - /** Required. Departure airport IATA code. */ - public Builder setAirport(String airport) { - this.airport = airport; - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.FlightData build() { + return new PaymentIntentConfirmParams.PaymentDetails.FlightData( + this.affiliate, + this.bookingNumber, + this.computerizedReservationSystem, + this.endorsementsAndRestrictions, + this.extraParams, + this.insurances, + this.passengers, + this.segments, + this.ticketElectronicallyIssuedIndicator, + this.total, + this.transactionType); + } - /** Departure city. */ - public Builder setCity(String city) { - this.city = city; - return this; - } + /** Affiliate details if applicable. */ + public Builder setAffiliate( + PaymentIntentConfirmParams.PaymentDetails.FlightData.Affiliate affiliate) { + this.affiliate = affiliate; + return this; + } - /** Departure country. */ - public Builder setCountry(String country) { - this.country = country; - return this; - } + /** Reservation reference. */ + public Builder setBookingNumber(String bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } - /** Required. Departure date/time. */ - public Builder setDepartsAt(Long departsAt) { - this.departsAt = departsAt; - return this; - } + /** Computerized reservation system used to make the reservation and purchase the ticket. */ + public Builder setComputerizedReservationSystem(String computerizedReservationSystem) { + this.computerizedReservationSystem = computerizedReservationSystem; + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Departure#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Ticket restrictions. */ + public Builder setEndorsementsAndRestrictions(String endorsementsAndRestrictions) { + this.endorsementsAndRestrictions = endorsementsAndRestrictions; + return this; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Departure#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.FlightData#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.put(key, value); + return this; } - public enum ServiceClass implements ApiRequestParams.EnumParam { - @SerializedName("business") - BUSINESS("business"), + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.FlightData#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - @SerializedName("economy") - ECONOMY("economy"), + /** + * Add an element to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData#insurances} for the field + * documentation. + */ + public Builder addInsurance( + PaymentIntentConfirmParams.PaymentDetails.FlightData.Insurance element) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); + } + this.insurances.add(element); + return this; + } - @SerializedName("first_class") - FIRST_CLASS("first_class"), + /** + * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData#insurances} for the field + * documentation. + */ + public Builder addAllInsurance( + List elements) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); + } + this.insurances.addAll(elements); + return this; + } - @SerializedName("premium_economy") - PREMIUM_ECONOMY("premium_economy"); + /** + * Add an element to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData#passengers} for the field + * documentation. + */ + public Builder addPassenger( + PaymentIntentConfirmParams.PaymentDetails.FlightData.Passenger element) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.add(element); + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** + * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData#passengers} for the field + * documentation. + */ + public Builder addAllPassenger( + List elements) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.addAll(elements); + return this; + } - ServiceClass(String value) { - this.value = value; + /** + * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData#segments} for the field + * documentation. + */ + public Builder addSegment( + PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment element) { + if (this.segments == null) { + this.segments = new ArrayList<>(); } + this.segments.add(element); + return this; } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Total { - /** Required. Total flight amount. */ - @SerializedName("amount") - Long amount; + /** + * Add all elements to `segments` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData#segments} for the field + * documentation. + */ + public Builder addAllSegment( + List elements) { + if (this.segments == null) { + this.segments = new ArrayList<>(); + } + this.segments.addAll(elements); + return this; + } - /** Reason for credit. */ - @SerializedName("credit_reason") - CreditReason creditReason; + /** Electronic ticket indicator. */ + public Builder setTicketElectronicallyIssuedIndicator( + Boolean ticketElectronicallyIssuedIndicator) { + this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; + return this; + } - /** Total currency. */ - @SerializedName("currency") - String currency; + /** Required. Total cost breakdown. */ + public Builder setTotal(PaymentIntentConfirmParams.PaymentDetails.FlightData.Total total) { + this.total = total; + return this; + } - /** Discount details. */ - @SerializedName("discounts") - Discounts discounts; + /** Type of flight transaction. */ + public Builder setTransactionType( + PaymentIntentConfirmParams.PaymentDetails.FlightData.TransactionType transactionType) { + this.transactionType = transactionType; + return this; + } + } - /** Additional charges. */ - @SerializedName("extra_charges") - List extraCharges; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Affiliate { + /** Affiliate partner code. */ + @SerializedName("code") + String code; /** * Map of extra parameters for custom features not available in this client library. The @@ -9951,26 +10409,134 @@ public static class Total { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Tax breakdown. */ - @SerializedName("tax") - Tax tax; + /** Name of affiliate partner. */ + @SerializedName("name") + String name; - private Total( + /** Code provided by the company to a travel agent authorizing ticket issuance. */ + @SerializedName("travel_authorization_code") + String travelAuthorizationCode; + + private Affiliate( + String code, + Map extraParams, + String name, + String travelAuthorizationCode) { + this.code = code; + this.extraParams = extraParams; + this.name = name; + this.travelAuthorizationCode = travelAuthorizationCode; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String code; + + private Map extraParams; + + private String name; + + private String travelAuthorizationCode; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.FlightData.Affiliate build() { + return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Affiliate( + this.code, this.extraParams, this.name, this.travelAuthorizationCode); + } + + /** Affiliate partner code. */ + public Builder setCode(String code) { + this.code = code; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Name of affiliate partner. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** Code provided by the company to a travel agent authorizing ticket issuance. */ + public Builder setTravelAuthorizationCode(String travelAuthorizationCode) { + this.travelAuthorizationCode = travelAuthorizationCode; + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Insurance { + /** Required. Insurance cost. */ + @SerializedName("amount") + Long amount; + + /** Insurance currency. */ + @SerializedName("currency") + String currency; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Insurance company name. */ + @SerializedName("insurance_company_name") + String insuranceCompanyName; + + /** Required. Type of insurance. */ + @SerializedName("insurance_type") + InsuranceType insuranceType; + + private Insurance( Long amount, - CreditReason creditReason, String currency, - Discounts discounts, - List - extraCharges, Map extraParams, - Tax tax) { + String insuranceCompanyName, + InsuranceType insuranceType) { this.amount = amount; - this.creditReason = creditReason; this.currency = currency; - this.discounts = discounts; - this.extraCharges = extraCharges; this.extraParams = extraParams; - this.tax = tax; + this.insuranceCompanyName = insuranceCompanyName; + this.insuranceType = insuranceType; } public static Builder builder() { @@ -9980,94 +10546,42 @@ public static Builder builder() { public static class Builder { private Long amount; - private CreditReason creditReason; - private String currency; - private Discounts discounts; - - private List - extraCharges; - private Map extraParams; - private Tax tax; + private String insuranceCompanyName; + + private InsuranceType insuranceType; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.FlightData.Total build() { - return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Total( + public PaymentIntentConfirmParams.PaymentDetails.FlightData.Insurance build() { + return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Insurance( this.amount, - this.creditReason, this.currency, - this.discounts, - this.extraCharges, this.extraParams, - this.tax); + this.insuranceCompanyName, + this.insuranceType); } - /** Required. Total flight amount. */ + /** Required. Insurance cost. */ public Builder setAmount(Long amount) { this.amount = amount; return this; } - /** Reason for credit. */ - public Builder setCreditReason( - PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.CreditReason - creditReason) { - this.creditReason = creditReason; - return this; - } - - /** Total currency. */ + /** Insurance currency. */ public Builder setCurrency(String currency) { this.currency = currency; return this; } - /** Discount details. */ - public Builder setDiscounts( - PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Discounts discounts) { - this.discounts = discounts; - return this; - } - - /** - * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total#extraCharges} for the field - * documentation. - */ - public Builder addExtraCharge( - PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.ExtraCharge element) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.add(element); - return this; - } - - /** - * Add all elements to `extraCharges` list. A list is initialized for the first - * `add/addAll` call, and subsequent calls adds additional elements to the original list. - * See {@link PaymentIntentConfirmParams.PaymentDetails.FlightData.Total#extraCharges} for - * the field documentation. - */ - public Builder addAllExtraCharge( - List - elements) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.addAll(elements); - return this; - } - /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.FlightData.Total#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Insurance#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -10080,8 +10594,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.FlightData.Total#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Insurance#extraParams} for the + * field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -10091,905 +10606,2182 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Tax breakdown. */ - public Builder setTax( - PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax tax) { - this.tax = tax; + /** Insurance company name. */ + public Builder setInsuranceCompanyName(String insuranceCompanyName) { + this.insuranceCompanyName = insuranceCompanyName; return this; } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Discounts { - /** Corporate client discount code. */ - @SerializedName("corporate_client_code") - String corporateClientCode; - - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; - private Discounts(String corporateClientCode, Map extraParams) { - this.corporateClientCode = corporateClientCode; - this.extraParams = extraParams; + /** Required. Type of insurance. */ + public Builder setInsuranceType( + PaymentIntentConfirmParams.PaymentDetails.FlightData.Insurance.InsuranceType + insuranceType) { + this.insuranceType = insuranceType; + return this; } + } - public static Builder builder() { - return new Builder(); - } + public enum InsuranceType implements ApiRequestParams.EnumParam { + @SerializedName("baggage") + BAGGAGE("baggage"), - public static class Builder { - private String corporateClientCode; + @SerializedName("bankruptcy") + BANKRUPTCY("bankruptcy"), - private Map extraParams; + @SerializedName("cancelation") + CANCELATION("cancelation"), - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Discounts build() { - return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Discounts( - this.corporateClientCode, this.extraParams); - } + @SerializedName("emergency") + EMERGENCY("emergency"), - /** Corporate client discount code. */ - public Builder setCorporateClientCode(String corporateClientCode) { - this.corporateClientCode = corporateClientCode; - return this; - } + @SerializedName("medical") + MEDICAL("medical"); - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Discounts#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + @Getter(onMethod_ = {@Override}) + private final String value; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Discounts#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + InsuranceType(String value) { + this.value = value; } } + } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class ExtraCharge { - /** Amount of additional charges. */ - @SerializedName("amount") - Long amount; - - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; - - /** Type of additional charges. */ - @SerializedName("type") - Type type; - - private ExtraCharge(Long amount, Map extraParams, Type type) { - this.amount = amount; - this.extraParams = extraParams; - this.type = type; - } - - public static Builder builder() { - return new Builder(); - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Passenger { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - public static class Builder { - private Long amount; + /** Required. Passenger's full name. */ + @SerializedName("name") + String name; - private Map extraParams; + private Passenger(Map extraParams, String name) { + this.extraParams = extraParams; + this.name = name; + } - private Type type; + public static Builder builder() { + return new Builder(); + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.ExtraCharge build() { - return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.ExtraCharge( - this.amount, this.extraParams, this.type); - } + public static class Builder { + private Map extraParams; - /** Amount of additional charges. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + private String name; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.ExtraCharge#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.FlightData.Passenger build() { + return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Passenger( + this.extraParams, this.name); + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.ExtraCharge#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Passenger#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.put(key, value); + return this; + } - /** Type of additional charges. */ - public Builder setType( - PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.ExtraCharge.Type type) { - this.type = type; - return this; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Passenger#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.putAll(map); + return this; } - public enum Type implements ApiRequestParams.EnumParam { - @SerializedName("additional_fees") - ADDITIONAL_FEES("additional_fees"), - - @SerializedName("ancillary_service_charges") - ANCILLARY_SERVICE_CHARGES("ancillary_service_charges"), - - @SerializedName("exchange_fee") - EXCHANGE_FEE("exchange_fee"); - - @Getter(onMethod_ = {@Override}) - private final String value; - - Type(String value) { - this.value = value; - } + /** Required. Passenger's full name. */ + public Builder setName(String name) { + this.name = name; + return this; } } + } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Tax { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Segment { + /** Segment fare amount. */ + @SerializedName("amount") + Long amount; - /** Array of tax details. */ - @SerializedName("taxes") - List taxes; + /** Required. Arrival details. */ + @SerializedName("arrival") + Arrival arrival; - private Tax( - Map extraParams, - List taxes) { - this.extraParams = extraParams; - this.taxes = taxes; - } + /** Required. Airline carrier code. */ + @SerializedName("carrier_code") + String carrierCode; - public static Builder builder() { - return new Builder(); - } + /** Carrier name. */ + @SerializedName("carrier_name") + String carrierName; - public static class Builder { - private Map extraParams; + /** Segment currency. */ + @SerializedName("currency") + String currency; - private List - taxes; + /** Required. Departure details. */ + @SerializedName("departure") + Departure departure; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax build() { - return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax( - this.extraParams, this.taxes); - } + /** Exchange ticket number. */ + @SerializedName("exchange_ticket_number") + String exchangeTicketNumber; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } - - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** - * Add an element to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addTax( - PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax.InnerTax element) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.add(element); - return this; - } + /** Fare basis code. */ + @SerializedName("fare_basis_code") + String fareBasisCode; - /** - * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addAllTax( - List - elements) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.addAll(elements); - return this; - } - } + /** Additional fees. */ + @SerializedName("fees") + Long fees; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class InnerTax { - /** Tax amount. */ - @SerializedName("amount") - Long amount; + /** Flight number. */ + @SerializedName("flight_number") + String flightNumber; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} - * value. Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** Stopover indicator. */ + @SerializedName("is_stop_over_indicator") + Boolean isStopOverIndicator; - /** Tax rate. */ - @SerializedName("rate") - Long rate; + /** Refundable ticket indicator. */ + @SerializedName("refundable") + Boolean refundable; - /** Type of tax. */ - @SerializedName("type") - String type; + /** Required. Class of service. */ + @SerializedName("service_class") + ServiceClass serviceClass; - private InnerTax(Long amount, Map extraParams, Long rate, String type) { - this.amount = amount; - this.extraParams = extraParams; - this.rate = rate; - this.type = type; - } + /** Tax amount for segment. */ + @SerializedName("tax_amount") + Long taxAmount; - public static Builder builder() { - return new Builder(); - } + /** Ticket number. */ + @SerializedName("ticket_number") + String ticketNumber; - public static class Builder { - private Long amount; + private Segment( + Long amount, + Arrival arrival, + String carrierCode, + String carrierName, + String currency, + Departure departure, + String exchangeTicketNumber, + Map extraParams, + String fareBasisCode, + Long fees, + String flightNumber, + Boolean isStopOverIndicator, + Boolean refundable, + ServiceClass serviceClass, + Long taxAmount, + String ticketNumber) { + this.amount = amount; + this.arrival = arrival; + this.carrierCode = carrierCode; + this.carrierName = carrierName; + this.currency = currency; + this.departure = departure; + this.exchangeTicketNumber = exchangeTicketNumber; + this.extraParams = extraParams; + this.fareBasisCode = fareBasisCode; + this.fees = fees; + this.flightNumber = flightNumber; + this.isStopOverIndicator = isStopOverIndicator; + this.refundable = refundable; + this.serviceClass = serviceClass; + this.taxAmount = taxAmount; + this.ticketNumber = ticketNumber; + } - private Map extraParams; + public static Builder builder() { + return new Builder(); + } - private Long rate; + public static class Builder { + private Long amount; - private String type; + private Arrival arrival; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax.InnerTax - build() { - return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax.InnerTax( - this.amount, this.extraParams, this.rate, this.type); - } + private String carrierCode; - /** Tax amount. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + private String carrierName; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax.InnerTax#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + private String currency; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the - * first `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax.InnerTax#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + private Departure departure; - /** Tax rate. */ - public Builder setRate(Long rate) { - this.rate = rate; - return this; - } + private String exchangeTicketNumber; - /** Type of tax. */ - public Builder setType(String type) { - this.type = type; - return this; - } - } - } - } + private Map extraParams; - public enum CreditReason implements ApiRequestParams.EnumParam { - @SerializedName("other") - OTHER("other"), + private String fareBasisCode; - @SerializedName("partial_ticket_refund") - PARTIAL_TICKET_REFUND("partial_ticket_refund"), + private Long fees; - @SerializedName("passenger_transport_ancillary_cancellation") - PASSENGER_TRANSPORT_ANCILLARY_CANCELLATION("passenger_transport_ancillary_cancellation"), + private String flightNumber; - @SerializedName("ticket_and_ancillary_cancellation") - TICKET_AND_ANCILLARY_CANCELLATION("ticket_and_ancillary_cancellation"), + private Boolean isStopOverIndicator; - @SerializedName("ticket_cancellation") - TICKET_CANCELLATION("ticket_cancellation"); + private Boolean refundable; - @Getter(onMethod_ = {@Override}) - private final String value; + private ServiceClass serviceClass; - CreditReason(String value) { - this.value = value; - } - } - } + private Long taxAmount; - public enum TransactionType implements ApiRequestParams.EnumParam { - @SerializedName("exchange_ticket") - EXCHANGE_TICKET("exchange_ticket"), + private String ticketNumber; - @SerializedName("miscellaneous") - MISCELLANEOUS("miscellaneous"), + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment build() { + return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment( + this.amount, + this.arrival, + this.carrierCode, + this.carrierName, + this.currency, + this.departure, + this.exchangeTicketNumber, + this.extraParams, + this.fareBasisCode, + this.fees, + this.flightNumber, + this.isStopOverIndicator, + this.refundable, + this.serviceClass, + this.taxAmount, + this.ticketNumber); + } - @SerializedName("refund") - REFUND("refund"), + /** Segment fare amount. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } - @SerializedName("ticket_purchase") - TICKET_PURCHASE("ticket_purchase"); + /** Required. Arrival details. */ + public Builder setArrival( + PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Arrival arrival) { + this.arrival = arrival; + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** Required. Airline carrier code. */ + public Builder setCarrierCode(String carrierCode) { + this.carrierCode = carrierCode; + return this; + } - TransactionType(String value) { - this.value = value; - } - } - } + /** Carrier name. */ + public Builder setCarrierName(String carrierName) { + this.carrierName = carrierName; + return this; + } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Lodging { - /** The lodging location's address. */ - @SerializedName("address") - Address address; + /** Segment currency. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; + } - /** The number of adults on the booking. */ - @SerializedName("adults") - Long adults; + /** Required. Departure details. */ + public Builder setDeparture( + PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Departure departure) { + this.departure = departure; + return this; + } - /** Affiliate details for this purchase. */ - @SerializedName("affiliate") - Affiliate affiliate; + /** Exchange ticket number. */ + public Builder setExchangeTicketNumber(String exchangeTicketNumber) { + this.exchangeTicketNumber = exchangeTicketNumber; + return this; + } - /** The booking number associated with the lodging reservation. */ - @SerializedName("booking_number") - String bookingNumber; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment#extraParams} for the field + * documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** The lodging category. */ - @SerializedName("category") - Category category; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment#extraParams} for the field + * documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** - * Required. Lodging check-in time. Measured in seconds since the Unix epoch. - */ - @SerializedName("checkin_at") - Long checkinAt; + /** Fare basis code. */ + public Builder setFareBasisCode(String fareBasisCode) { + this.fareBasisCode = fareBasisCode; + return this; + } - /** - * Required. Lodging check-out time. Measured in seconds since the Unix - * epoch. - */ - @SerializedName("checkout_at") - Long checkoutAt; + /** Additional fees. */ + public Builder setFees(Long fees) { + this.fees = fees; + return this; + } - /** The customer service phone number of the lodging company. */ - @SerializedName("customer_service_phone_number") - String customerServicePhoneNumber; + /** Flight number. */ + public Builder setFlightNumber(String flightNumber) { + this.flightNumber = flightNumber; + return this; + } - /** The daily lodging room rate. */ - @SerializedName("daily_room_rate_amount") - Long dailyRoomRateAmount; + /** Stopover indicator. */ + public Builder setIsStopOverIndicator(Boolean isStopOverIndicator) { + this.isStopOverIndicator = isStopOverIndicator; + return this; + } - /** Delivery details for this purchase. */ - @SerializedName("delivery") - Delivery delivery; + /** Refundable ticket indicator. */ + public Builder setRefundable(Boolean refundable) { + this.refundable = refundable; + return this; + } - /** List of additional charges being billed. */ - @SerializedName("extra_charges") - List extraCharges; + /** Required. Class of service. */ + public Builder setServiceClass( + PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.ServiceClass + serviceClass) { + this.serviceClass = serviceClass; + return this; + } - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) - * name in this param object. Effectively, this map is flattened to its parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** Tax amount for segment. */ + public Builder setTaxAmount(Long taxAmount) { + this.taxAmount = taxAmount; + return this; + } - /** Indicates whether the lodging location is compliant with the Fire Safety Act. */ - @SerializedName("fire_safety_act_compliance") - Boolean fireSafetyActCompliance; + /** Ticket number. */ + public Builder setTicketNumber(String ticketNumber) { + this.ticketNumber = ticketNumber; + return this; + } + } - /** The name of the lodging location. */ - @SerializedName("name") - String name; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Arrival { + /** Required. Arrival airport IATA code. */ + @SerializedName("airport") + String airport; - /** - * Indicates if the customer did not keep their booking while failing to cancel the - * reservation. - */ - @SerializedName("no_show") - Boolean noShow; + /** Arrival date/time. */ + @SerializedName("arrives_at") + Long arrivesAt; - /** The number of rooms on the booking. */ - @SerializedName("number_of_rooms") - Long numberOfRooms; + /** Arrival city. */ + @SerializedName("city") + String city; - /** The details of the passengers in the travel reservation. */ - @SerializedName("passengers") - List passengers; + /** Arrival country. */ + @SerializedName("country") + String country; - /** The phone number of the lodging location. */ - @SerializedName("property_phone_number") - String propertyPhoneNumber; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** The room class for this purchase. */ - @SerializedName("room_class") - String roomClass; + private Arrival( + String airport, + Long arrivesAt, + String city, + String country, + Map extraParams) { + this.airport = airport; + this.arrivesAt = arrivesAt; + this.city = city; + this.country = country; + this.extraParams = extraParams; + } - /** The number of room nights. */ - @SerializedName("room_nights") - Long roomNights; + public static Builder builder() { + return new Builder(); + } - /** The total tax amount associating with the room reservation. */ - @SerializedName("total_room_tax_amount") - Long totalRoomTaxAmount; - - /** The total tax amount. */ - @SerializedName("total_tax_amount") - Long totalTaxAmount; + public static class Builder { + private String airport; - private Lodging( - Address address, - Long adults, - Affiliate affiliate, - String bookingNumber, - Category category, - Long checkinAt, - Long checkoutAt, - String customerServicePhoneNumber, - Long dailyRoomRateAmount, - Delivery delivery, - List extraCharges, - Map extraParams, - Boolean fireSafetyActCompliance, - String name, - Boolean noShow, - Long numberOfRooms, - List passengers, - String propertyPhoneNumber, - String roomClass, - Long roomNights, - Long totalRoomTaxAmount, - Long totalTaxAmount) { - this.address = address; - this.adults = adults; - this.affiliate = affiliate; - this.bookingNumber = bookingNumber; - this.category = category; - this.checkinAt = checkinAt; - this.checkoutAt = checkoutAt; - this.customerServicePhoneNumber = customerServicePhoneNumber; - this.dailyRoomRateAmount = dailyRoomRateAmount; - this.delivery = delivery; - this.extraCharges = extraCharges; - this.extraParams = extraParams; - this.fireSafetyActCompliance = fireSafetyActCompliance; - this.name = name; - this.noShow = noShow; - this.numberOfRooms = numberOfRooms; - this.passengers = passengers; - this.propertyPhoneNumber = propertyPhoneNumber; - this.roomClass = roomClass; - this.roomNights = roomNights; - this.totalRoomTaxAmount = totalRoomTaxAmount; - this.totalTaxAmount = totalTaxAmount; - } + private Long arrivesAt; - public static Builder builder() { - return new Builder(); - } + private String city; - public static class Builder { - private Address address; + private String country; - private Long adults; + private Map extraParams; - private Affiliate affiliate; + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Arrival build() { + return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Arrival( + this.airport, this.arrivesAt, this.city, this.country, this.extraParams); + } - private String bookingNumber; + /** Required. Arrival airport IATA code. */ + public Builder setAirport(String airport) { + this.airport = airport; + return this; + } - private Category category; + /** Arrival date/time. */ + public Builder setArrivesAt(Long arrivesAt) { + this.arrivesAt = arrivesAt; + return this; + } - private Long checkinAt; + /** Arrival city. */ + public Builder setCity(String city) { + this.city = city; + return this; + } - private Long checkoutAt; + /** Arrival country. */ + public Builder setCountry(String country) { + this.country = country; + return this; + } - private String customerServicePhoneNumber; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Arrival#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - private Long dailyRoomRateAmount; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Arrival#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } - private Delivery delivery; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Departure { + /** Required. Departure airport IATA code. */ + @SerializedName("airport") + String airport; - private List extraCharges; + /** Departure city. */ + @SerializedName("city") + String city; - private Map extraParams; + /** Departure country. */ + @SerializedName("country") + String country; - private Boolean fireSafetyActCompliance; + /** Required. Departure date/time. */ + @SerializedName("departs_at") + Long departsAt; - private String name; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private Boolean noShow; + private Departure( + String airport, + String city, + String country, + Long departsAt, + Map extraParams) { + this.airport = airport; + this.city = city; + this.country = country; + this.departsAt = departsAt; + this.extraParams = extraParams; + } - private Long numberOfRooms; + public static Builder builder() { + return new Builder(); + } - private List passengers; + public static class Builder { + private String airport; - private String propertyPhoneNumber; + private String city; - private String roomClass; + private String country; - private Long roomNights; + private Long departsAt; - private Long totalRoomTaxAmount; + private Map extraParams; - private Long totalTaxAmount; + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Departure build() { + return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Departure( + this.airport, this.city, this.country, this.departsAt, this.extraParams); + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.Lodging build() { - return new PaymentIntentConfirmParams.PaymentDetails.Lodging( - this.address, - this.adults, - this.affiliate, - this.bookingNumber, - this.category, - this.checkinAt, - this.checkoutAt, - this.customerServicePhoneNumber, - this.dailyRoomRateAmount, - this.delivery, - this.extraCharges, - this.extraParams, - this.fireSafetyActCompliance, - this.name, - this.noShow, - this.numberOfRooms, - this.passengers, - this.propertyPhoneNumber, - this.roomClass, - this.roomNights, - this.totalRoomTaxAmount, - this.totalTaxAmount); - } + /** Required. Departure airport IATA code. */ + public Builder setAirport(String airport) { + this.airport = airport; + return this; + } - /** The lodging location's address. */ - public Builder setAddress( - PaymentIntentConfirmParams.PaymentDetails.Lodging.Address address) { - this.address = address; - return this; - } + /** Departure city. */ + public Builder setCity(String city) { + this.city = city; + return this; + } - /** The number of adults on the booking. */ - public Builder setAdults(Long adults) { - this.adults = adults; - return this; - } + /** Departure country. */ + public Builder setCountry(String country) { + this.country = country; + return this; + } - /** Affiliate details for this purchase. */ - public Builder setAffiliate( - PaymentIntentConfirmParams.PaymentDetails.Lodging.Affiliate affiliate) { - this.affiliate = affiliate; - return this; - } + /** Required. Departure date/time. */ + public Builder setDepartsAt(Long departsAt) { + this.departsAt = departsAt; + return this; + } - /** The booking number associated with the lodging reservation. */ - public Builder setBookingNumber(String bookingNumber) { - this.bookingNumber = bookingNumber; - return this; - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Departure#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** The lodging category. */ - public Builder setCategory( - PaymentIntentConfirmParams.PaymentDetails.Lodging.Category category) { - this.category = category; - return this; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Segment.Departure#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } } - /** - * Required. Lodging check-in time. Measured in seconds since the Unix - * epoch. - */ - public Builder setCheckinAt(Long checkinAt) { - this.checkinAt = checkinAt; - return this; - } + public enum ServiceClass implements ApiRequestParams.EnumParam { + @SerializedName("business") + BUSINESS("business"), - /** - * Required. Lodging check-out time. Measured in seconds since the Unix - * epoch. - */ - public Builder setCheckoutAt(Long checkoutAt) { - this.checkoutAt = checkoutAt; - return this; - } + @SerializedName("economy") + ECONOMY("economy"), - /** The customer service phone number of the lodging company. */ - public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { - this.customerServicePhoneNumber = customerServicePhoneNumber; - return this; - } + @SerializedName("first_class") + FIRST_CLASS("first_class"), - /** The daily lodging room rate. */ - public Builder setDailyRoomRateAmount(Long dailyRoomRateAmount) { - this.dailyRoomRateAmount = dailyRoomRateAmount; - return this; - } + @SerializedName("premium_economy") + PREMIUM_ECONOMY("premium_economy"); - /** Delivery details for this purchase. */ - public Builder setDelivery( - PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery delivery) { - this.delivery = delivery; - return this; - } + @Getter(onMethod_ = {@Override}) + private final String value; - /** - * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.Lodging#extraCharges} for the field - * documentation. - */ - public Builder addExtraCharge( - PaymentIntentConfirmParams.PaymentDetails.Lodging.ExtraCharge element) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); + ServiceClass(String value) { + this.value = value; } - this.extraCharges.add(element); - return this; } + } - /** - * Add all elements to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.Lodging#extraCharges} for the field - * documentation. - */ - public Builder addAllExtraCharge( - List elements) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.addAll(elements); - return this; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Total { + /** Required. Total flight amount. */ + @SerializedName("amount") + Long amount; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Lodging#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Reason for credit. */ + @SerializedName("credit_reason") + CreditReason creditReason; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Lodging#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** Total currency. */ + @SerializedName("currency") + String currency; - /** Indicates whether the lodging location is compliant with the Fire Safety Act. */ - public Builder setFireSafetyActCompliance(Boolean fireSafetyActCompliance) { - this.fireSafetyActCompliance = fireSafetyActCompliance; - return this; - } + /** Discount details. */ + @SerializedName("discounts") + Discounts discounts; - /** The name of the lodging location. */ - public Builder setName(String name) { - this.name = name; - return this; - } + /** Additional charges. */ + @SerializedName("extra_charges") + List extraCharges; /** - * Indicates if the customer did not keep their booking while failing to cancel the - * reservation. + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. */ - public Builder setNoShow(Boolean noShow) { - this.noShow = noShow; - return this; - } + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** The number of rooms on the booking. */ - public Builder setNumberOfRooms(Long numberOfRooms) { - this.numberOfRooms = numberOfRooms; - return this; - } + /** Tax breakdown. */ + @SerializedName("tax") + Tax tax; - /** - * Add an element to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.Lodging#passengers} for the field - * documentation. - */ - public Builder addPassenger( - PaymentIntentConfirmParams.PaymentDetails.Lodging.Passenger element) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.add(element); - return this; + private Total( + Long amount, + CreditReason creditReason, + String currency, + Discounts discounts, + List + extraCharges, + Map extraParams, + Tax tax) { + this.amount = amount; + this.creditReason = creditReason; + this.currency = currency; + this.discounts = discounts; + this.extraCharges = extraCharges; + this.extraParams = extraParams; + this.tax = tax; } - /** - * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.Lodging#passengers} for the field - * documentation. - */ - public Builder addAllPassenger( - List elements) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.addAll(elements); - return this; + public static Builder builder() { + return new Builder(); } - /** The phone number of the lodging location. */ - public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { - this.propertyPhoneNumber = propertyPhoneNumber; - return this; - } + public static class Builder { + private Long amount; - /** The room class for this purchase. */ - public Builder setRoomClass(String roomClass) { - this.roomClass = roomClass; - return this; - } + private CreditReason creditReason; - /** The number of room nights. */ - public Builder setRoomNights(Long roomNights) { - this.roomNights = roomNights; - return this; - } + private String currency; - /** The total tax amount associating with the room reservation. */ - public Builder setTotalRoomTaxAmount(Long totalRoomTaxAmount) { - this.totalRoomTaxAmount = totalRoomTaxAmount; - return this; - } + private Discounts discounts; + + private List + extraCharges; + + private Map extraParams; + + private Tax tax; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.FlightData.Total build() { + return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Total( + this.amount, + this.creditReason, + this.currency, + this.discounts, + this.extraCharges, + this.extraParams, + this.tax); + } + + /** Required. Total flight amount. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Reason for credit. */ + public Builder setCreditReason( + PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.CreditReason + creditReason) { + this.creditReason = creditReason; + return this; + } + + /** Total currency. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; + } + + /** Discount details. */ + public Builder setDiscounts( + PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Discounts discounts) { + this.discounts = discounts; + return this; + } + + /** + * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total#extraCharges} for the field + * documentation. + */ + public Builder addExtraCharge( + PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.ExtraCharge element) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.add(element); + return this; + } + + /** + * Add all elements to `extraCharges` list. A list is initialized for the first + * `add/addAll` call, and subsequent calls adds additional elements to the original list. + * See {@link PaymentIntentConfirmParams.PaymentDetails.FlightData.Total#extraCharges} for + * the field documentation. + */ + public Builder addAllExtraCharge( + List + elements) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.addAll(elements); + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.FlightData.Total#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.FlightData.Total#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Tax breakdown. */ + public Builder setTax( + PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax tax) { + this.tax = tax; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Discounts { + /** Corporate client discount code. */ + @SerializedName("corporate_client_code") + String corporateClientCode; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Discounts(String corporateClientCode, Map extraParams) { + this.corporateClientCode = corporateClientCode; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String corporateClientCode; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Discounts build() { + return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Discounts( + this.corporateClientCode, this.extraParams); + } + + /** Corporate client discount code. */ + public Builder setCorporateClientCode(String corporateClientCode) { + this.corporateClientCode = corporateClientCode; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Discounts#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Discounts#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ExtraCharge { + /** Amount of additional charges. */ + @SerializedName("amount") + Long amount; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Type of additional charges. */ + @SerializedName("type") + Type type; + + private ExtraCharge(Long amount, Map extraParams, Type type) { + this.amount = amount; + this.extraParams = extraParams; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private Map extraParams; + + private Type type; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.ExtraCharge build() { + return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.ExtraCharge( + this.amount, this.extraParams, this.type); + } + + /** Amount of additional charges. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.ExtraCharge#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.ExtraCharge#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Type of additional charges. */ + public Builder setType( + PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.ExtraCharge.Type type) { + this.type = type; + return this; + } + } + + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("additional_fees") + ADDITIONAL_FEES("additional_fees"), + + @SerializedName("ancillary_service_charges") + ANCILLARY_SERVICE_CHARGES("ancillary_service_charges"), + + @SerializedName("exchange_fee") + EXCHANGE_FEE("exchange_fee"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Type(String value) { + this.value = value; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Tax { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Array of tax details. */ + @SerializedName("taxes") + List taxes; + + private Tax( + Map extraParams, + List taxes) { + this.extraParams = extraParams; + this.taxes = taxes; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private List + taxes; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax build() { + return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax( + this.extraParams, this.taxes); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Add an element to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax#taxes} for the field + * documentation. + */ + public Builder addTax( + PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax.InnerTax element) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.add(element); + return this; + } + + /** + * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax#taxes} for the field + * documentation. + */ + public Builder addAllTax( + List + elements) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.addAll(elements); + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class InnerTax { + /** Tax amount. */ + @SerializedName("amount") + Long amount; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Tax rate. */ + @SerializedName("rate") + Long rate; + + /** Type of tax. */ + @SerializedName("type") + String type; + + private InnerTax(Long amount, Map extraParams, Long rate, String type) { + this.amount = amount; + this.extraParams = extraParams; + this.rate = rate; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private Map extraParams; + + private Long rate; + + private String type; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax.InnerTax + build() { + return new PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax.InnerTax( + this.amount, this.extraParams, this.rate, this.type); + } + + /** Tax amount. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax.InnerTax#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.FlightData.Total.Tax.InnerTax#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Tax rate. */ + public Builder setRate(Long rate) { + this.rate = rate; + return this; + } + + /** Type of tax. */ + public Builder setType(String type) { + this.type = type; + return this; + } + } + } + } + + public enum CreditReason implements ApiRequestParams.EnumParam { + @SerializedName("other") + OTHER("other"), + + @SerializedName("partial_ticket_refund") + PARTIAL_TICKET_REFUND("partial_ticket_refund"), + + @SerializedName("passenger_transport_ancillary_cancellation") + PASSENGER_TRANSPORT_ANCILLARY_CANCELLATION("passenger_transport_ancillary_cancellation"), + + @SerializedName("ticket_and_ancillary_cancellation") + TICKET_AND_ANCILLARY_CANCELLATION("ticket_and_ancillary_cancellation"), + + @SerializedName("ticket_cancellation") + TICKET_CANCELLATION("ticket_cancellation"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + CreditReason(String value) { + this.value = value; + } + } + } + + public enum TransactionType implements ApiRequestParams.EnumParam { + @SerializedName("exchange_ticket") + EXCHANGE_TICKET("exchange_ticket"), + + @SerializedName("miscellaneous") + MISCELLANEOUS("miscellaneous"), + + @SerializedName("refund") + REFUND("refund"), + + @SerializedName("ticket_purchase") + TICKET_PURCHASE("ticket_purchase"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + TransactionType(String value) { + this.value = value; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Lodging { + /** The lodging location's address. */ + @SerializedName("address") + Address address; + + /** The number of adults on the booking. */ + @SerializedName("adults") + Long adults; + + /** Affiliate details for this purchase. */ + @SerializedName("affiliate") + Affiliate affiliate; + + /** The booking number associated with the lodging reservation. */ + @SerializedName("booking_number") + String bookingNumber; + + /** The lodging category. */ + @SerializedName("category") + Category category; + + /** + * Required. Lodging check-in time. Measured in seconds since the Unix epoch. + */ + @SerializedName("checkin_at") + Long checkinAt; + + /** + * Required. Lodging check-out time. Measured in seconds since the Unix + * epoch. + */ + @SerializedName("checkout_at") + Long checkoutAt; + + /** The customer service phone number of the lodging company. */ + @SerializedName("customer_service_phone_number") + String customerServicePhoneNumber; + + /** The daily lodging room rate. */ + @SerializedName("daily_room_rate_amount") + Long dailyRoomRateAmount; + + /** Delivery details for this purchase. */ + @SerializedName("delivery") + Delivery delivery; + + /** List of additional charges being billed. */ + @SerializedName("extra_charges") + List extraCharges; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Indicates whether the lodging location is compliant with the Fire Safety Act. */ + @SerializedName("fire_safety_act_compliance") + Boolean fireSafetyActCompliance; + + /** The name of the lodging location. */ + @SerializedName("name") + String name; + + /** + * Indicates if the customer did not keep their booking while failing to cancel the + * reservation. + */ + @SerializedName("no_show") + Boolean noShow; + + /** The number of rooms on the booking. */ + @SerializedName("number_of_rooms") + Long numberOfRooms; + + /** The details of the passengers in the travel reservation. */ + @SerializedName("passengers") + List passengers; + + /** The phone number of the lodging location. */ + @SerializedName("property_phone_number") + String propertyPhoneNumber; + + /** The room class for this purchase. */ + @SerializedName("room_class") + String roomClass; + + /** The number of room nights. */ + @SerializedName("room_nights") + Long roomNights; + + /** The total tax amount associating with the room reservation. */ + @SerializedName("total_room_tax_amount") + Long totalRoomTaxAmount; + + /** The total tax amount. */ + @SerializedName("total_tax_amount") + Long totalTaxAmount; + + private Lodging( + Address address, + Long adults, + Affiliate affiliate, + String bookingNumber, + Category category, + Long checkinAt, + Long checkoutAt, + String customerServicePhoneNumber, + Long dailyRoomRateAmount, + Delivery delivery, + List extraCharges, + Map extraParams, + Boolean fireSafetyActCompliance, + String name, + Boolean noShow, + Long numberOfRooms, + List passengers, + String propertyPhoneNumber, + String roomClass, + Long roomNights, + Long totalRoomTaxAmount, + Long totalTaxAmount) { + this.address = address; + this.adults = adults; + this.affiliate = affiliate; + this.bookingNumber = bookingNumber; + this.category = category; + this.checkinAt = checkinAt; + this.checkoutAt = checkoutAt; + this.customerServicePhoneNumber = customerServicePhoneNumber; + this.dailyRoomRateAmount = dailyRoomRateAmount; + this.delivery = delivery; + this.extraCharges = extraCharges; + this.extraParams = extraParams; + this.fireSafetyActCompliance = fireSafetyActCompliance; + this.name = name; + this.noShow = noShow; + this.numberOfRooms = numberOfRooms; + this.passengers = passengers; + this.propertyPhoneNumber = propertyPhoneNumber; + this.roomClass = roomClass; + this.roomNights = roomNights; + this.totalRoomTaxAmount = totalRoomTaxAmount; + this.totalTaxAmount = totalTaxAmount; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Address address; + + private Long adults; + + private Affiliate affiliate; + + private String bookingNumber; + + private Category category; + + private Long checkinAt; + + private Long checkoutAt; + + private String customerServicePhoneNumber; + + private Long dailyRoomRateAmount; + + private Delivery delivery; + + private List extraCharges; + + private Map extraParams; + + private Boolean fireSafetyActCompliance; + + private String name; + + private Boolean noShow; + + private Long numberOfRooms; + + private List passengers; + + private String propertyPhoneNumber; + + private String roomClass; + + private Long roomNights; + + private Long totalRoomTaxAmount; + + private Long totalTaxAmount; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.Lodging build() { + return new PaymentIntentConfirmParams.PaymentDetails.Lodging( + this.address, + this.adults, + this.affiliate, + this.bookingNumber, + this.category, + this.checkinAt, + this.checkoutAt, + this.customerServicePhoneNumber, + this.dailyRoomRateAmount, + this.delivery, + this.extraCharges, + this.extraParams, + this.fireSafetyActCompliance, + this.name, + this.noShow, + this.numberOfRooms, + this.passengers, + this.propertyPhoneNumber, + this.roomClass, + this.roomNights, + this.totalRoomTaxAmount, + this.totalTaxAmount); + } + + /** The lodging location's address. */ + public Builder setAddress( + PaymentIntentConfirmParams.PaymentDetails.Lodging.Address address) { + this.address = address; + return this; + } + + /** The number of adults on the booking. */ + public Builder setAdults(Long adults) { + this.adults = adults; + return this; + } + + /** Affiliate details for this purchase. */ + public Builder setAffiliate( + PaymentIntentConfirmParams.PaymentDetails.Lodging.Affiliate affiliate) { + this.affiliate = affiliate; + return this; + } + + /** The booking number associated with the lodging reservation. */ + public Builder setBookingNumber(String bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } + + /** The lodging category. */ + public Builder setCategory( + PaymentIntentConfirmParams.PaymentDetails.Lodging.Category category) { + this.category = category; + return this; + } + + /** + * Required. Lodging check-in time. Measured in seconds since the Unix + * epoch. + */ + public Builder setCheckinAt(Long checkinAt) { + this.checkinAt = checkinAt; + return this; + } + + /** + * Required. Lodging check-out time. Measured in seconds since the Unix + * epoch. + */ + public Builder setCheckoutAt(Long checkoutAt) { + this.checkoutAt = checkoutAt; + return this; + } + + /** The customer service phone number of the lodging company. */ + public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; + } + + /** The daily lodging room rate. */ + public Builder setDailyRoomRateAmount(Long dailyRoomRateAmount) { + this.dailyRoomRateAmount = dailyRoomRateAmount; + return this; + } + + /** Delivery details for this purchase. */ + public Builder setDelivery( + PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery delivery) { + this.delivery = delivery; + return this; + } + + /** + * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.Lodging#extraCharges} for the field + * documentation. + */ + public Builder addExtraCharge( + PaymentIntentConfirmParams.PaymentDetails.Lodging.ExtraCharge element) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.add(element); + return this; + } + + /** + * Add all elements to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.Lodging#extraCharges} for the field + * documentation. + */ + public Builder addAllExtraCharge( + List elements) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.addAll(elements); + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Lodging#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Lodging#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Indicates whether the lodging location is compliant with the Fire Safety Act. */ + public Builder setFireSafetyActCompliance(Boolean fireSafetyActCompliance) { + this.fireSafetyActCompliance = fireSafetyActCompliance; + return this; + } + + /** The name of the lodging location. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** + * Indicates if the customer did not keep their booking while failing to cancel the + * reservation. + */ + public Builder setNoShow(Boolean noShow) { + this.noShow = noShow; + return this; + } + + /** The number of rooms on the booking. */ + public Builder setNumberOfRooms(Long numberOfRooms) { + this.numberOfRooms = numberOfRooms; + return this; + } + + /** + * Add an element to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.Lodging#passengers} for the field + * documentation. + */ + public Builder addPassenger( + PaymentIntentConfirmParams.PaymentDetails.Lodging.Passenger element) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.add(element); + return this; + } + + /** + * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.Lodging#passengers} for the field + * documentation. + */ + public Builder addAllPassenger( + List elements) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.addAll(elements); + return this; + } + + /** The phone number of the lodging location. */ + public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { + this.propertyPhoneNumber = propertyPhoneNumber; + return this; + } + + /** The room class for this purchase. */ + public Builder setRoomClass(String roomClass) { + this.roomClass = roomClass; + return this; + } + + /** The number of room nights. */ + public Builder setRoomNights(Long roomNights) { + this.roomNights = roomNights; + return this; + } + + /** The total tax amount associating with the room reservation. */ + public Builder setTotalRoomTaxAmount(Long totalRoomTaxAmount) { + this.totalRoomTaxAmount = totalRoomTaxAmount; + return this; + } + + /** The total tax amount. */ + public Builder setTotalTaxAmount(Long totalTaxAmount) { + this.totalTaxAmount = totalTaxAmount; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Address { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + String city; + + /** + * Two-letter country code (ISO + * 3166-1 alpha-2). + */ + @SerializedName("country") + String country; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Address line 1, such as the street, PO Box, or company name. */ + @SerializedName("line1") + String line1; + + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; + + /** ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; + + private Address( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String city; + + private String country; + + private Map extraParams; + + private String line1; + + private String line2; + + private String postalCode; + + private String state; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.Lodging.Address build() { + return new PaymentIntentConfirmParams.PaymentDetails.Lodging.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } + + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO + * 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Lodging.Address#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Lodging.Address#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } + + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } + + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } + + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Affiliate { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Required. The name of the affiliate that originated the purchase. */ + @SerializedName("name") + String name; + + private Affiliate(Map extraParams, String name) { + this.extraParams = extraParams; + this.name = name; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String name; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.Lodging.Affiliate build() { + return new PaymentIntentConfirmParams.PaymentDetails.Lodging.Affiliate( + this.extraParams, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.Lodging.Affiliate#extraParams} for the field + * documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.Lodging.Affiliate#extraParams} for the field + * documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Required. The name of the affiliate that originated the purchase. */ + public Builder setName(String name) { + this.name = name; + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Delivery { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The delivery method for the payment. */ + @SerializedName("mode") + Mode mode; + + /** Details of the recipient. */ + @SerializedName("recipient") + Recipient recipient; + + private Delivery(Map extraParams, Mode mode, Recipient recipient) { + this.extraParams = extraParams; + this.mode = mode; + this.recipient = recipient; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Mode mode; + + private Recipient recipient; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery build() { + return new PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery( + this.extraParams, this.mode, this.recipient); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The delivery method for the payment. */ + public Builder setMode( + PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery.Mode mode) { + this.mode = mode; + return this; + } + + /** Details of the recipient. */ + public Builder setRecipient( + PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery.Recipient recipient) { + this.recipient = recipient; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Recipient { + /** The email of the recipient the ticket is delivered to. */ + @SerializedName("email") + String email; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The name of the recipient the ticket is delivered to. */ + @SerializedName("name") + String name; + + /** The phone number of the recipient the ticket is delivered to. */ + @SerializedName("phone") + String phone; + + private Recipient( + String email, Map extraParams, String name, String phone) { + this.email = email; + this.extraParams = extraParams; + this.name = name; + this.phone = phone; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String email; + + private Map extraParams; + + private String name; + + private String phone; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery.Recipient build() { + return new PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery.Recipient( + this.email, this.extraParams, this.name, this.phone); + } + + /** The email of the recipient the ticket is delivered to. */ + public Builder setEmail(String email) { + this.email = email; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The name of the recipient the ticket is delivered to. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** The phone number of the recipient the ticket is delivered to. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } + } + } + + public enum Mode implements ApiRequestParams.EnumParam { + @SerializedName("email") + EMAIL("email"), + + @SerializedName("phone") + PHONE("phone"), + + @SerializedName("pickup") + PICKUP("pickup"), + + @SerializedName("post") + POST("post"); + + @Getter(onMethod_ = {@Override}) + private final String value; - /** The total tax amount. */ - public Builder setTotalTaxAmount(Long totalTaxAmount) { - this.totalTaxAmount = totalTaxAmount; - return this; + Mode(String value) { + this.value = value; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Address { - /** City, district, suburb, town, or village. */ - @SerializedName("city") - String city; - - /** - * Two-letter country code (ISO - * 3166-1 alpha-2). - */ - @SerializedName("country") - String country; - + public static class Passenger { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -11000,40 +12792,15 @@ public static class Address { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Address line 1, such as the street, PO Box, or company name. */ - @SerializedName("line1") - String line1; - - /** Address line 2, such as the apartment, suite, unit, or building. */ - @SerializedName("line2") - String line2; - - /** ZIP or postal code. */ - @SerializedName("postal_code") - String postalCode; - /** - * State, county, province, or region (ISO 3166-2). + * Required. Full name of the person or entity on the lodging reservation. */ - @SerializedName("state") - String state; + @SerializedName("name") + String name; - private Address( - String city, - String country, - Map extraParams, - String line1, - String line2, - String postalCode, - String state) { - this.city = city; - this.country = country; + private Passenger(Map extraParams, String name) { this.extraParams = extraParams; - this.line1 = line1; - this.line2 = line2; - this.postalCode = postalCode; - this.state = state; + this.name = name; } public static Builder builder() { @@ -11041,52 +12808,22 @@ public static Builder builder() { } public static class Builder { - private String city; - - private String country; - private Map extraParams; - private String line1; - - private String line2; - - private String postalCode; - - private String state; + private String name; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.Lodging.Address build() { - return new PaymentIntentConfirmParams.PaymentDetails.Lodging.Address( - this.city, - this.country, - this.extraParams, - this.line1, - this.line2, - this.postalCode, - this.state); - } - - /** City, district, suburb, town, or village. */ - public Builder setCity(String city) { - this.city = city; - return this; - } - - /** - * Two-letter country code (ISO - * 3166-1 alpha-2). - */ - public Builder setCountry(String country) { - this.country = country; - return this; + public PaymentIntentConfirmParams.PaymentDetails.Lodging.Passenger build() { + return new PaymentIntentConfirmParams.PaymentDetails.Lodging.Passenger( + this.extraParams, this.name); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Lodging.Address#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.Lodging.Passenger#extraParams} for the field + * documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -11099,8 +12836,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Lodging.Address#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.Lodging.Passenger#extraParams} for the field + * documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -11110,324 +12848,395 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Address line 1, such as the street, PO Box, or company name. */ - public Builder setLine1(String line1) { - this.line1 = line1; - return this; - } - - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(String line2) { - this.line2 = line2; - return this; - } - - /** ZIP or postal code. */ - public Builder setPostalCode(String postalCode) { - this.postalCode = postalCode; - return this; - } - /** - * State, county, province, or region (ISO 3166-2). + * Required. Full name of the person or entity on the lodging + * reservation. */ - public Builder setState(String state) { - this.state = state; + public Builder setName(String name) { + this.name = name; return this; } } } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Affiliate { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public enum Category implements ApiRequestParams.EnumParam { + @SerializedName("hotel") + HOTEL("hotel"), - /** Required. The name of the affiliate that originated the purchase. */ - @SerializedName("name") - String name; + @SerializedName("vacation_rental") + VACATION_RENTAL("vacation_rental"); - private Affiliate(Map extraParams, String name) { - this.extraParams = extraParams; - this.name = name; + @Getter(onMethod_ = {@Override}) + private final String value; + + Category(String value) { + this.value = value; } + } - public static Builder builder() { - return new Builder(); + public enum ExtraCharge implements ApiRequestParams.EnumParam { + @SerializedName("gift_shop") + GIFT_SHOP("gift_shop"), + + @SerializedName("laundry") + LAUNDRY("laundry"), + + @SerializedName("mini_bar") + MINI_BAR("mini_bar"), + + @SerializedName("other") + OTHER("other"), + + @SerializedName("restaurant") + RESTAURANT("restaurant"), + + @SerializedName("telephone") + TELEPHONE("telephone"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ExtraCharge(String value) { + this.value = value; } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class LodgingData { + /** Accommodation details for the lodging. */ + @SerializedName("accommodation") + Accommodation accommodation; + + /** Affiliate details if applicable. */ + @SerializedName("affiliate") + Affiliate affiliate; + + /** Booking confirmation number for the lodging. */ + @SerializedName("booking_number") + String bookingNumber; + + /** Required. Check-in date. */ + @SerializedName("checkin_at") + Long checkinAt; + + /** Required. Check-out date. */ + @SerializedName("checkout_at") + Long checkoutAt; + + /** Customer service phone number for the lodging company. */ + @SerializedName("customer_service_phone_number") + String customerServicePhoneNumber; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Whether the lodging is compliant with any hotel fire safety regulations. */ + @SerializedName("fire_safety_act_compliance_indicator") + Boolean fireSafetyActComplianceIndicator; + + /** List of guests for the lodging. */ + @SerializedName("guests") + List guests; + + /** Host details for the lodging. */ + @SerializedName("host") + Host host; + + /** List of insurances for the lodging. */ + @SerializedName("insurances") + List insurances; + + /** Whether the renter is a no-show. */ + @SerializedName("no_show_indicator") + Boolean noShowIndicator; + + /** Renter ID number for the lodging. */ + @SerializedName("renter_id_number") + String renterIdNumber; + + /** Renter name for the lodging. */ + @SerializedName("renter_name") + String renterName; + + /** Required. Total details for the lodging. */ + @SerializedName("total") + Total total; - public static class Builder { - private Map extraParams; + private LodgingData( + Accommodation accommodation, + Affiliate affiliate, + String bookingNumber, + Long checkinAt, + Long checkoutAt, + String customerServicePhoneNumber, + Map extraParams, + Boolean fireSafetyActComplianceIndicator, + List guests, + Host host, + List insurances, + Boolean noShowIndicator, + String renterIdNumber, + String renterName, + Total total) { + this.accommodation = accommodation; + this.affiliate = affiliate; + this.bookingNumber = bookingNumber; + this.checkinAt = checkinAt; + this.checkoutAt = checkoutAt; + this.customerServicePhoneNumber = customerServicePhoneNumber; + this.extraParams = extraParams; + this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; + this.guests = guests; + this.host = host; + this.insurances = insurances; + this.noShowIndicator = noShowIndicator; + this.renterIdNumber = renterIdNumber; + this.renterName = renterName; + this.total = total; + } - private String name; + public static Builder builder() { + return new Builder(); + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.Lodging.Affiliate build() { - return new PaymentIntentConfirmParams.PaymentDetails.Lodging.Affiliate( - this.extraParams, this.name); - } + public static class Builder { + private Accommodation accommodation; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.Lodging.Affiliate#extraParams} for the field - * documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + private Affiliate affiliate; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.Lodging.Affiliate#extraParams} for the field - * documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + private String bookingNumber; - /** Required. The name of the affiliate that originated the purchase. */ - public Builder setName(String name) { - this.name = name; - return this; - } - } - } + private Long checkinAt; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Delivery { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private Long checkoutAt; - /** The delivery method for the payment. */ - @SerializedName("mode") - Mode mode; + private String customerServicePhoneNumber; - /** Details of the recipient. */ - @SerializedName("recipient") - Recipient recipient; + private Map extraParams; - private Delivery(Map extraParams, Mode mode, Recipient recipient) { - this.extraParams = extraParams; - this.mode = mode; - this.recipient = recipient; - } + private Boolean fireSafetyActComplianceIndicator; - public static Builder builder() { - return new Builder(); - } + private List guests; - public static class Builder { - private Map extraParams; + private Host host; - private Mode mode; + private List insurances; - private Recipient recipient; + private Boolean noShowIndicator; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery build() { - return new PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery( - this.extraParams, this.mode, this.recipient); - } + private String renterIdNumber; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + private String renterName; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + private Total total; - /** The delivery method for the payment. */ - public Builder setMode( - PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery.Mode mode) { - this.mode = mode; - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.LodgingData build() { + return new PaymentIntentConfirmParams.PaymentDetails.LodgingData( + this.accommodation, + this.affiliate, + this.bookingNumber, + this.checkinAt, + this.checkoutAt, + this.customerServicePhoneNumber, + this.extraParams, + this.fireSafetyActComplianceIndicator, + this.guests, + this.host, + this.insurances, + this.noShowIndicator, + this.renterIdNumber, + this.renterName, + this.total); + } - /** Details of the recipient. */ - public Builder setRecipient( - PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery.Recipient recipient) { - this.recipient = recipient; - return this; - } + /** Accommodation details for the lodging. */ + public Builder setAccommodation( + PaymentIntentConfirmParams.PaymentDetails.LodgingData.Accommodation accommodation) { + this.accommodation = accommodation; + return this; } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Recipient { - /** The email of the recipient the ticket is delivered to. */ - @SerializedName("email") - String email; + /** Affiliate details if applicable. */ + public Builder setAffiliate( + PaymentIntentConfirmParams.PaymentDetails.LodgingData.Affiliate affiliate) { + this.affiliate = affiliate; + return this; + } - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** Booking confirmation number for the lodging. */ + public Builder setBookingNumber(String bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } - /** The name of the recipient the ticket is delivered to. */ - @SerializedName("name") - String name; + /** Required. Check-in date. */ + public Builder setCheckinAt(Long checkinAt) { + this.checkinAt = checkinAt; + return this; + } - /** The phone number of the recipient the ticket is delivered to. */ - @SerializedName("phone") - String phone; + /** Required. Check-out date. */ + public Builder setCheckoutAt(Long checkoutAt) { + this.checkoutAt = checkoutAt; + return this; + } - private Recipient( - String email, Map extraParams, String name, String phone) { - this.email = email; - this.extraParams = extraParams; - this.name = name; - this.phone = phone; - } + /** Customer service phone number for the lodging company. */ + public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; + } - public static Builder builder() { - return new Builder(); + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.LodgingData#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.put(key, value); + return this; + } - public static class Builder { - private String email; - - private Map extraParams; - - private String name; - - private String phone; - - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery.Recipient build() { - return new PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery.Recipient( - this.email, this.extraParams, this.name, this.phone); - } + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.LodgingData#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** The email of the recipient the ticket is delivered to. */ - public Builder setEmail(String email) { - this.email = email; - return this; - } + /** Whether the lodging is compliant with any hotel fire safety regulations. */ + public Builder setFireSafetyActComplianceIndicator( + Boolean fireSafetyActComplianceIndicator) { + this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** + * Add an element to `guests` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData#guests} for the field + * documentation. + */ + public Builder addGuest( + PaymentIntentConfirmParams.PaymentDetails.LodgingData.Guest element) { + if (this.guests == null) { + this.guests = new ArrayList<>(); + } + this.guests.add(element); + return this; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** + * Add all elements to `guests` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData#guests} for the field + * documentation. + */ + public Builder addAllGuest( + List elements) { + if (this.guests == null) { + this.guests = new ArrayList<>(); + } + this.guests.addAll(elements); + return this; + } - /** The name of the recipient the ticket is delivered to. */ - public Builder setName(String name) { - this.name = name; - return this; - } + /** Host details for the lodging. */ + public Builder setHost(PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host host) { + this.host = host; + return this; + } - /** The phone number of the recipient the ticket is delivered to. */ - public Builder setPhone(String phone) { - this.phone = phone; - return this; - } + /** + * Add an element to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData#insurances} for the field + * documentation. + */ + public Builder addInsurance( + PaymentIntentConfirmParams.PaymentDetails.LodgingData.Insurance element) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); } + this.insurances.add(element); + return this; } - public enum Mode implements ApiRequestParams.EnumParam { - @SerializedName("email") - EMAIL("email"), - - @SerializedName("phone") - PHONE("phone"), + /** + * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData#insurances} for the field + * documentation. + */ + public Builder addAllInsurance( + List elements) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); + } + this.insurances.addAll(elements); + return this; + } - @SerializedName("pickup") - PICKUP("pickup"), + /** Whether the renter is a no-show. */ + public Builder setNoShowIndicator(Boolean noShowIndicator) { + this.noShowIndicator = noShowIndicator; + return this; + } - @SerializedName("post") - POST("post"); + /** Renter ID number for the lodging. */ + public Builder setRenterIdNumber(String renterIdNumber) { + this.renterIdNumber = renterIdNumber; + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** Renter name for the lodging. */ + public Builder setRenterName(String renterName) { + this.renterName = renterName; + return this; + } - Mode(String value) { - this.value = value; - } + /** Required. Total details for the lodging. */ + public Builder setTotal(PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total total) { + this.total = total; + return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Passenger { + public static class Accommodation { + /** Type of accommodation. */ + @SerializedName("accommodation_type") + AccommodationType accommodationType; + + /** Bed type. */ + @SerializedName("bed_type") + String bedType; + + /** Daily accommodation rate in cents. */ + @SerializedName("daily_rate_amount") + Long dailyRateAmount; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -11438,15 +13247,39 @@ public static class Passenger { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** - * Required. Full name of the person or entity on the lodging reservation. - */ - @SerializedName("name") - String name; + /** Number of nights. */ + @SerializedName("nights") + Long nights; - private Passenger(Map extraParams, String name) { + /** Number of rooms, cabanas, apartments, and so on. */ + @SerializedName("number_of_rooms") + Long numberOfRooms; + + /** Rate type. */ + @SerializedName("rate_type") + String rateType; + + /** Whether smoking is allowed. */ + @SerializedName("smoking_indicator") + Boolean smokingIndicator; + + private Accommodation( + AccommodationType accommodationType, + String bedType, + Long dailyRateAmount, + Map extraParams, + Long nights, + Long numberOfRooms, + String rateType, + Boolean smokingIndicator) { + this.accommodationType = accommodationType; + this.bedType = bedType; + this.dailyRateAmount = dailyRateAmount; this.extraParams = extraParams; - this.name = name; + this.nights = nights; + this.numberOfRooms = numberOfRooms; + this.rateType = rateType; + this.smokingIndicator = smokingIndicator; } public static Builder builder() { @@ -11454,22 +13287,61 @@ public static Builder builder() { } public static class Builder { + private AccommodationType accommodationType; + + private String bedType; + + private Long dailyRateAmount; + private Map extraParams; - private String name; + private Long nights; + + private Long numberOfRooms; + + private String rateType; + + private Boolean smokingIndicator; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Accommodation build() { + return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Accommodation( + this.accommodationType, + this.bedType, + this.dailyRateAmount, + this.extraParams, + this.nights, + this.numberOfRooms, + this.rateType, + this.smokingIndicator); + } + + /** Type of accommodation. */ + public Builder setAccommodationType( + PaymentIntentConfirmParams.PaymentDetails.LodgingData.Accommodation.AccommodationType + accommodationType) { + this.accommodationType = accommodationType; + return this; + } + + /** Bed type. */ + public Builder setBedType(String bedType) { + this.bedType = bedType; + return this; + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.Lodging.Passenger build() { - return new PaymentIntentConfirmParams.PaymentDetails.Lodging.Passenger( - this.extraParams, this.name); + /** Daily accommodation rate in cents. */ + public Builder setDailyRateAmount(Long dailyRateAmount) { + this.dailyRateAmount = dailyRateAmount; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.Lodging.Passenger#extraParams} for the field - * documentation. + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Accommodation#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -11483,8 +13355,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.Lodging.Passenger#extraParams} for the field - * documentation. + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Accommodation#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -11494,394 +13366,238 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Required. Full name of the person or entity on the lodging - * reservation. - */ - public Builder setName(String name) { - this.name = name; + /** Number of nights. */ + public Builder setNights(Long nights) { + this.nights = nights; return this; } - } - } - - public enum Category implements ApiRequestParams.EnumParam { - @SerializedName("hotel") - HOTEL("hotel"), - - @SerializedName("vacation_rental") - VACATION_RENTAL("vacation_rental"); - - @Getter(onMethod_ = {@Override}) - private final String value; - - Category(String value) { - this.value = value; - } - } - - public enum ExtraCharge implements ApiRequestParams.EnumParam { - @SerializedName("gift_shop") - GIFT_SHOP("gift_shop"), - - @SerializedName("laundry") - LAUNDRY("laundry"), - - @SerializedName("mini_bar") - MINI_BAR("mini_bar"), - - @SerializedName("other") - OTHER("other"), - @SerializedName("restaurant") - RESTAURANT("restaurant"), - - @SerializedName("telephone") - TELEPHONE("telephone"); + /** Number of rooms, cabanas, apartments, and so on. */ + public Builder setNumberOfRooms(Long numberOfRooms) { + this.numberOfRooms = numberOfRooms; + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** Rate type. */ + public Builder setRateType(String rateType) { + this.rateType = rateType; + return this; + } - ExtraCharge(String value) { - this.value = value; + /** Whether smoking is allowed. */ + public Builder setSmokingIndicator(Boolean smokingIndicator) { + this.smokingIndicator = smokingIndicator; + return this; + } } - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class LodgingData { - /** Accommodation details for the lodging. */ - @SerializedName("accommodation") - Accommodation accommodation; - - /** Affiliate details if applicable. */ - @SerializedName("affiliate") - Affiliate affiliate; - - /** Booking confirmation number for the lodging. */ - @SerializedName("booking_number") - String bookingNumber; - - /** Required. Check-in date. */ - @SerializedName("checkin_at") - Long checkinAt; - - /** Required. Check-out date. */ - @SerializedName("checkout_at") - Long checkoutAt; - - /** Customer service phone number for the lodging company. */ - @SerializedName("customer_service_phone_number") - String customerServicePhoneNumber; - - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) - * name in this param object. Effectively, this map is flattened to its parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; - - /** Whether the lodging is compliant with any hotel fire safety regulations. */ - @SerializedName("fire_safety_act_compliance_indicator") - Boolean fireSafetyActComplianceIndicator; - - /** List of guests for the lodging. */ - @SerializedName("guests") - List guests; - - /** Host details for the lodging. */ - @SerializedName("host") - Host host; - - /** List of insurances for the lodging. */ - @SerializedName("insurances") - List insurances; - - /** Whether the renter is a no-show. */ - @SerializedName("no_show_indicator") - Boolean noShowIndicator; - - /** Renter ID number for the lodging. */ - @SerializedName("renter_id_number") - String renterIdNumber; - - /** Renter name for the lodging. */ - @SerializedName("renter_name") - String renterName; - - /** Required. Total details for the lodging. */ - @SerializedName("total") - Total total; - - private LodgingData( - Accommodation accommodation, - Affiliate affiliate, - String bookingNumber, - Long checkinAt, - Long checkoutAt, - String customerServicePhoneNumber, - Map extraParams, - Boolean fireSafetyActComplianceIndicator, - List guests, - Host host, - List insurances, - Boolean noShowIndicator, - String renterIdNumber, - String renterName, - Total total) { - this.accommodation = accommodation; - this.affiliate = affiliate; - this.bookingNumber = bookingNumber; - this.checkinAt = checkinAt; - this.checkoutAt = checkoutAt; - this.customerServicePhoneNumber = customerServicePhoneNumber; - this.extraParams = extraParams; - this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; - this.guests = guests; - this.host = host; - this.insurances = insurances; - this.noShowIndicator = noShowIndicator; - this.renterIdNumber = renterIdNumber; - this.renterName = renterName; - this.total = total; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private Accommodation accommodation; - - private Affiliate affiliate; - - private String bookingNumber; - - private Long checkinAt; - - private Long checkoutAt; - - private String customerServicePhoneNumber; - - private Map extraParams; - - private Boolean fireSafetyActComplianceIndicator; - - private List guests; - - private Host host; - - private List insurances; - - private Boolean noShowIndicator; - - private String renterIdNumber; - - private String renterName; - private Total total; + public enum AccommodationType implements ApiRequestParams.EnumParam { + @SerializedName("apartment") + APARTMENT("apartment"), - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.LodgingData build() { - return new PaymentIntentConfirmParams.PaymentDetails.LodgingData( - this.accommodation, - this.affiliate, - this.bookingNumber, - this.checkinAt, - this.checkoutAt, - this.customerServicePhoneNumber, - this.extraParams, - this.fireSafetyActComplianceIndicator, - this.guests, - this.host, - this.insurances, - this.noShowIndicator, - this.renterIdNumber, - this.renterName, - this.total); - } + @SerializedName("cabana") + CABANA("cabana"), - /** Accommodation details for the lodging. */ - public Builder setAccommodation( - PaymentIntentConfirmParams.PaymentDetails.LodgingData.Accommodation accommodation) { - this.accommodation = accommodation; - return this; - } + @SerializedName("house") + HOUSE("house"), - /** Affiliate details if applicable. */ - public Builder setAffiliate( - PaymentIntentConfirmParams.PaymentDetails.LodgingData.Affiliate affiliate) { - this.affiliate = affiliate; - return this; - } + @SerializedName("penthouse") + PENTHOUSE("penthouse"), - /** Booking confirmation number for the lodging. */ - public Builder setBookingNumber(String bookingNumber) { - this.bookingNumber = bookingNumber; - return this; - } + @SerializedName("room") + ROOM("room"), - /** Required. Check-in date. */ - public Builder setCheckinAt(Long checkinAt) { - this.checkinAt = checkinAt; - return this; - } + @SerializedName("standard") + STANDARD("standard"), - /** Required. Check-out date. */ - public Builder setCheckoutAt(Long checkoutAt) { - this.checkoutAt = checkoutAt; - return this; - } + @SerializedName("suite") + SUITE("suite"), - /** Customer service phone number for the lodging company. */ - public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { - this.customerServicePhoneNumber = customerServicePhoneNumber; - return this; - } + @SerializedName("villa") + VILLA("villa"); - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.LodgingData#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + @Getter(onMethod_ = {@Override}) + private final String value; + + AccommodationType(String value) { + this.value = value; } - this.extraParams.put(key, value); - return this; } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Affiliate { + /** Affiliate partner code. */ + @SerializedName("code") + String code; /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.LodgingData#extraParams} for - * the field documentation. + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Affiliate partner name. */ + @SerializedName("name") + String name; + + private Affiliate(String code, Map extraParams, String name) { + this.code = code; + this.extraParams = extraParams; + this.name = name; } - /** Whether the lodging is compliant with any hotel fire safety regulations. */ - public Builder setFireSafetyActComplianceIndicator( - Boolean fireSafetyActComplianceIndicator) { - this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; - return this; + public static Builder builder() { + return new Builder(); } - /** - * Add an element to `guests` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData#guests} for the field - * documentation. - */ - public Builder addGuest( - PaymentIntentConfirmParams.PaymentDetails.LodgingData.Guest element) { - if (this.guests == null) { - this.guests = new ArrayList<>(); + public static class Builder { + private String code; + + private Map extraParams; + + private String name; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Affiliate build() { + return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Affiliate( + this.code, this.extraParams, this.name); } - this.guests.add(element); - return this; - } - /** - * Add all elements to `guests` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData#guests} for the field - * documentation. - */ - public Builder addAllGuest( - List elements) { - if (this.guests == null) { - this.guests = new ArrayList<>(); + /** Affiliate partner code. */ + public Builder setCode(String code) { + this.code = code; + return this; } - this.guests.addAll(elements); - return this; - } - /** Host details for the lodging. */ - public Builder setHost(PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host host) { - this.host = host; - return this; - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** - * Add an element to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData#insurances} for the field - * documentation. - */ - public Builder addInsurance( - PaymentIntentConfirmParams.PaymentDetails.LodgingData.Insurance element) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Affiliate partner name. */ + public Builder setName(String name) { + this.name = name; + return this; } - this.insurances.add(element); - return this; } + } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Guest { /** - * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData#insurances} for the field - * documentation. + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. */ - public Builder addAllInsurance( - List elements) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); - } - this.insurances.addAll(elements); - return this; - } + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Whether the renter is a no-show. */ - public Builder setNoShowIndicator(Boolean noShowIndicator) { - this.noShowIndicator = noShowIndicator; - return this; - } + /** Required. Guest's full name. */ + @SerializedName("name") + String name; - /** Renter ID number for the lodging. */ - public Builder setRenterIdNumber(String renterIdNumber) { - this.renterIdNumber = renterIdNumber; - return this; + private Guest(Map extraParams, String name) { + this.extraParams = extraParams; + this.name = name; } - /** Renter name for the lodging. */ - public Builder setRenterName(String renterName) { - this.renterName = renterName; - return this; + public static Builder builder() { + return new Builder(); } - /** Required. Total details for the lodging. */ - public Builder setTotal(PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total total) { - this.total = total; - return this; + public static class Builder { + private Map extraParams; + + private String name; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Guest build() { + return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Guest( + this.extraParams, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Guest#extraParams} for the field + * documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Guest#extraParams} for the field + * documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Required. Guest's full name. */ + public Builder setName(String name) { + this.name = name; + return this; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Accommodation { - /** Type of accommodation. */ - @SerializedName("accommodation_type") - AccommodationType accommodationType; - - /** Bed type. */ - @SerializedName("bed_type") - String bedType; + public static class Host { + /** Address of the host. */ + @SerializedName("address") + Address address; - /** Daily accommodation rate in cents. */ - @SerializedName("daily_rate_amount") - Long dailyRateAmount; + /** Host's country of domicile. */ + @SerializedName("country_of_domicile") + String countryOfDomicile; /** * Map of extra parameters for custom features not available in this client library. The @@ -11893,39 +13609,49 @@ public static class Accommodation { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Number of nights. */ - @SerializedName("nights") - Long nights; + /** Reference number for the host. */ + @SerializedName("host_reference") + String hostReference; - /** Number of rooms, cabanas, apartments, and so on. */ - @SerializedName("number_of_rooms") - Long numberOfRooms; + /** Type of host. */ + @SerializedName("host_type") + HostType hostType; - /** Rate type. */ - @SerializedName("rate_type") - String rateType; + /** Name of the lodging property or host. */ + @SerializedName("name") + String name; - /** Whether smoking is allowed. */ - @SerializedName("smoking_indicator") - Boolean smokingIndicator; + /** Total number of reservations for the host. */ + @SerializedName("number_of_reservations") + Long numberOfReservations; - private Accommodation( - AccommodationType accommodationType, - String bedType, - Long dailyRateAmount, + /** Property phone number. */ + @SerializedName("property_phone_number") + String propertyPhoneNumber; + + /** Host's registration date. */ + @SerializedName("registered_at") + Long registeredAt; + + private Host( + Address address, + String countryOfDomicile, Map extraParams, - Long nights, - Long numberOfRooms, - String rateType, - Boolean smokingIndicator) { - this.accommodationType = accommodationType; - this.bedType = bedType; - this.dailyRateAmount = dailyRateAmount; + String hostReference, + HostType hostType, + String name, + Long numberOfReservations, + String propertyPhoneNumber, + Long registeredAt) { + this.address = address; + this.countryOfDomicile = countryOfDomicile; this.extraParams = extraParams; - this.nights = nights; - this.numberOfRooms = numberOfRooms; - this.rateType = rateType; - this.smokingIndicator = smokingIndicator; + this.hostReference = hostReference; + this.hostType = hostType; + this.name = name; + this.numberOfReservations = numberOfReservations; + this.propertyPhoneNumber = propertyPhoneNumber; + this.registeredAt = registeredAt; } public static Builder builder() { @@ -11933,61 +13659,56 @@ public static Builder builder() { } public static class Builder { - private AccommodationType accommodationType; - - private String bedType; + private Address address; - private Long dailyRateAmount; + private String countryOfDomicile; private Map extraParams; - private Long nights; + private String hostReference; - private Long numberOfRooms; + private HostType hostType; - private String rateType; + private String name; - private Boolean smokingIndicator; + private Long numberOfReservations; + + private String propertyPhoneNumber; + + private Long registeredAt; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Accommodation build() { - return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Accommodation( - this.accommodationType, - this.bedType, - this.dailyRateAmount, + public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host build() { + return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host( + this.address, + this.countryOfDomicile, this.extraParams, - this.nights, - this.numberOfRooms, - this.rateType, - this.smokingIndicator); - } - - /** Type of accommodation. */ - public Builder setAccommodationType( - PaymentIntentConfirmParams.PaymentDetails.LodgingData.Accommodation.AccommodationType - accommodationType) { - this.accommodationType = accommodationType; - return this; + this.hostReference, + this.hostType, + this.name, + this.numberOfReservations, + this.propertyPhoneNumber, + this.registeredAt); } - /** Bed type. */ - public Builder setBedType(String bedType) { - this.bedType = bedType; + /** Address of the host. */ + public Builder setAddress( + PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host.Address address) { + this.address = address; return this; } - /** Daily accommodation rate in cents. */ - public Builder setDailyRateAmount(Long dailyRateAmount) { - this.dailyRateAmount = dailyRateAmount; + /** Host's country of domicile. */ + public Builder setCountryOfDomicile(String countryOfDomicile) { + this.countryOfDomicile = countryOfDomicile; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Accommodation#extraParams} for - * the field documentation. + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -12000,9 +13721,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Accommodation#extraParams} for - * the field documentation. + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -12012,156 +13732,247 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Number of nights. */ - public Builder setNights(Long nights) { - this.nights = nights; + /** Reference number for the host. */ + public Builder setHostReference(String hostReference) { + this.hostReference = hostReference; + return this; + } + + /** Type of host. */ + public Builder setHostType( + PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host.HostType hostType) { + this.hostType = hostType; + return this; + } + + /** Name of the lodging property or host. */ + public Builder setName(String name) { + this.name = name; return this; } - /** Number of rooms, cabanas, apartments, and so on. */ - public Builder setNumberOfRooms(Long numberOfRooms) { - this.numberOfRooms = numberOfRooms; - return this; + /** Total number of reservations for the host. */ + public Builder setNumberOfReservations(Long numberOfReservations) { + this.numberOfReservations = numberOfReservations; + return this; + } + + /** Property phone number. */ + public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { + this.propertyPhoneNumber = propertyPhoneNumber; + return this; + } + + /** Host's registration date. */ + public Builder setRegisteredAt(Long registeredAt) { + this.registeredAt = registeredAt; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Address { + /** Required. City, district, suburb, town, or village. */ + @SerializedName("city") + String city; + + /** + * Required. Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + String country; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** + * Required. Address line 1, such as the street, PO Box, or company name. + */ + @SerializedName("line1") + String line1; + + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; + + /** Required. ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; + + private Address( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; } - /** Rate type. */ - public Builder setRateType(String rateType) { - this.rateType = rateType; - return this; + public static Builder builder() { + return new Builder(); } - /** Whether smoking is allowed. */ - public Builder setSmokingIndicator(Boolean smokingIndicator) { - this.smokingIndicator = smokingIndicator; - return this; - } - } + public static class Builder { + private String city; - public enum AccommodationType implements ApiRequestParams.EnumParam { - @SerializedName("apartment") - APARTMENT("apartment"), + private String country; - @SerializedName("cabana") - CABANA("cabana"), + private Map extraParams; - @SerializedName("house") - HOUSE("house"), + private String line1; - @SerializedName("penthouse") - PENTHOUSE("penthouse"), + private String line2; - @SerializedName("room") - ROOM("room"), + private String postalCode; - @SerializedName("standard") - STANDARD("standard"), + private String state; - @SerializedName("suite") - SUITE("suite"), + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host.Address build() { + return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } - @SerializedName("villa") - VILLA("villa"); + /** Required. City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** + * Required. Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } - AccommodationType(String value) { - this.value = value; - } - } - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host.Address#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Affiliate { - /** Affiliate partner code. */ - @SerializedName("code") - String code; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host.Address#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** + * Required. Address line 1, such as the street, PO Box, or company + * name. + */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } - /** Affiliate partner name. */ - @SerializedName("name") - String name; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } - private Affiliate(String code, Map extraParams, String name) { - this.code = code; - this.extraParams = extraParams; - this.name = name; - } + /** Required. ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - public static Builder builder() { - return new Builder(); + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + } } - public static class Builder { - private String code; - - private Map extraParams; - - private String name; + public enum HostType implements ApiRequestParams.EnumParam { + @SerializedName("hostel") + HOSTEL("hostel"), - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Affiliate build() { - return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Affiliate( - this.code, this.extraParams, this.name); - } + @SerializedName("hotel") + HOTEL("hotel"), - /** Affiliate partner code. */ - public Builder setCode(String code) { - this.code = code; - return this; - } + @SerializedName("owner") + OWNER("owner"), - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Affiliate#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + @SerializedName("rental_agency") + RENTAL_AGENCY("rental_agency"); - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Affiliate#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + @Getter(onMethod_ = {@Override}) + private final String value; - /** Affiliate partner name. */ - public Builder setName(String name) { - this.name = name; - return this; + HostType(String value) { + this.value = value; } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Guest { + public static class Insurance { + /** Required. Price of the insurance coverage in cents. */ + @SerializedName("amount") + Long amount; + + /** Currency of the insurance amount. */ + @SerializedName("currency") + String currency; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -12172,13 +13983,25 @@ public static class Guest { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Required. Guest's full name. */ - @SerializedName("name") - String name; + /** Name of the insurance company. */ + @SerializedName("insurance_company_name") + String insuranceCompanyName; - private Guest(Map extraParams, String name) { + /** Required. Type of insurance coverage. */ + @SerializedName("insurance_type") + InsuranceType insuranceType; + + private Insurance( + Long amount, + String currency, + Map extraParams, + String insuranceCompanyName, + InsuranceType insuranceType) { + this.amount = amount; + this.currency = currency; this.extraParams = extraParams; - this.name = name; + this.insuranceCompanyName = insuranceCompanyName; + this.insuranceType = insuranceType; } public static Builder builder() { @@ -12186,22 +14009,44 @@ public static Builder builder() { } public static class Builder { + private Long amount; + + private String currency; + private Map extraParams; - private String name; + private String insuranceCompanyName; + + private InsuranceType insuranceType; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Guest build() { - return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Guest( - this.extraParams, this.name); + public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Insurance build() { + return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Insurance( + this.amount, + this.currency, + this.extraParams, + this.insuranceCompanyName, + this.insuranceType); + } + + /** Required. Price of the insurance coverage in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Currency of the insurance amount. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Guest#extraParams} for the field - * documentation. + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Insurance#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -12215,8 +14060,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Guest#extraParams} for the field - * documentation. + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Insurance#extraParams} for the + * field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -12226,24 +14071,65 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Required. Guest's full name. */ - public Builder setName(String name) { - this.name = name; + /** Name of the insurance company. */ + public Builder setInsuranceCompanyName(String insuranceCompanyName) { + this.insuranceCompanyName = insuranceCompanyName; return this; } + + /** Required. Type of insurance coverage. */ + public Builder setInsuranceType( + PaymentIntentConfirmParams.PaymentDetails.LodgingData.Insurance.InsuranceType + insuranceType) { + this.insuranceType = insuranceType; + return this; + } + } + + public enum InsuranceType implements ApiRequestParams.EnumParam { + @SerializedName("bankruptcy") + BANKRUPTCY("bankruptcy"), + + @SerializedName("cancelation") + CANCELATION("cancelation"), + + @SerializedName("emergency") + EMERGENCY("emergency"), + + @SerializedName("medical") + MEDICAL("medical"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + InsuranceType(String value) { + this.value = value; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Host { - /** Address of the host. */ - @SerializedName("address") - Address address; + public static class Total { + /** Required. Total price of the lodging reservation in cents. */ + @SerializedName("amount") + Long amount; - /** Host's country of domicile. */ - @SerializedName("country_of_domicile") - String countryOfDomicile; + /** Cash advances in cents. */ + @SerializedName("cash_advances") + Long cashAdvances; + + /** Currency of the total amount. */ + @SerializedName("currency") + String currency; + + /** Discount details for the lodging. */ + @SerializedName("discounts") + Discounts discounts; + + /** Additional charges for the lodging. */ + @SerializedName("extra_charges") + List extraCharges; /** * Map of extra parameters for custom features not available in this client library. The @@ -12255,49 +14141,32 @@ public static class Host { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Reference number for the host. */ - @SerializedName("host_reference") - String hostReference; - - /** Type of host. */ - @SerializedName("host_type") - HostType hostType; - - /** Name of the lodging property or host. */ - @SerializedName("name") - String name; - - /** Total number of reservations for the host. */ - @SerializedName("number_of_reservations") - Long numberOfReservations; - - /** Property phone number. */ - @SerializedName("property_phone_number") - String propertyPhoneNumber; + /** Prepaid amount in cents. */ + @SerializedName("prepaid_amount") + Long prepaidAmount; - /** Host's registration date. */ - @SerializedName("registered_at") - Long registeredAt; + /** Tax breakdown for the lodging reservation. */ + @SerializedName("tax") + Tax tax; - private Host( - Address address, - String countryOfDomicile, + private Total( + Long amount, + Long cashAdvances, + String currency, + Discounts discounts, + List + extraCharges, Map extraParams, - String hostReference, - HostType hostType, - String name, - Long numberOfReservations, - String propertyPhoneNumber, - Long registeredAt) { - this.address = address; - this.countryOfDomicile = countryOfDomicile; + Long prepaidAmount, + Tax tax) { + this.amount = amount; + this.cashAdvances = cashAdvances; + this.currency = currency; + this.discounts = discounts; + this.extraCharges = extraCharges; this.extraParams = extraParams; - this.hostReference = hostReference; - this.hostType = hostType; - this.name = name; - this.numberOfReservations = numberOfReservations; - this.propertyPhoneNumber = propertyPhoneNumber; - this.registeredAt = registeredAt; + this.prepaidAmount = prepaidAmount; + this.tax = tax; } public static Builder builder() { @@ -12305,56 +14174,98 @@ public static Builder builder() { } public static class Builder { - private Address address; - - private String countryOfDomicile; + private Long amount; - private Map extraParams; + private Long cashAdvances; - private String hostReference; + private String currency; - private HostType hostType; + private Discounts discounts; - private String name; + private List + extraCharges; - private Long numberOfReservations; + private Map extraParams; - private String propertyPhoneNumber; + private Long prepaidAmount; - private Long registeredAt; + private Tax tax; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host build() { - return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host( - this.address, - this.countryOfDomicile, + public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total build() { + return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total( + this.amount, + this.cashAdvances, + this.currency, + this.discounts, + this.extraCharges, this.extraParams, - this.hostReference, - this.hostType, - this.name, - this.numberOfReservations, - this.propertyPhoneNumber, - this.registeredAt); + this.prepaidAmount, + this.tax); } - /** Address of the host. */ - public Builder setAddress( - PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host.Address address) { - this.address = address; + /** Required. Total price of the lodging reservation in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; return this; } - /** Host's country of domicile. */ - public Builder setCountryOfDomicile(String countryOfDomicile) { - this.countryOfDomicile = countryOfDomicile; + /** Cash advances in cents. */ + public Builder setCashAdvances(Long cashAdvances) { + this.cashAdvances = cashAdvances; + return this; + } + + /** Currency of the total amount. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; + } + + /** Discount details for the lodging. */ + public Builder setDiscounts( + PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Discounts discounts) { + this.discounts = discounts; + return this; + } + + /** + * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total#extraCharges} for the field + * documentation. + */ + public Builder addExtraCharge( + PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.ExtraCharge element) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.add(element); + return this; + } + + /** + * Add all elements to `extraCharges` list. A list is initialized for the first + * `add/addAll` call, and subsequent calls adds additional elements to the original list. + * See {@link PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total#extraCharges} + * for the field documentation. + */ + public Builder addAllExtraCharge( + List + elements) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.addAll(elements); return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total#extraParams} for the field + * documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -12367,8 +14278,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total#extraParams} for the field + * documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -12378,57 +14290,115 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Reference number for the host. */ - public Builder setHostReference(String hostReference) { - this.hostReference = hostReference; + /** Prepaid amount in cents. */ + public Builder setPrepaidAmount(Long prepaidAmount) { + this.prepaidAmount = prepaidAmount; return this; } - /** Type of host. */ - public Builder setHostType( - PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host.HostType hostType) { - this.hostType = hostType; + /** Tax breakdown for the lodging reservation. */ + public Builder setTax( + PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax tax) { + this.tax = tax; return this; } + } - /** Name of the lodging property or host. */ - public Builder setName(String name) { - this.name = name; - return this; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Discounts { + /** Corporate client discount code. */ + @SerializedName("corporate_client_code") + String corporateClientCode; - /** Total number of reservations for the host. */ - public Builder setNumberOfReservations(Long numberOfReservations) { - this.numberOfReservations = numberOfReservations; - return this; + /** Coupon code. */ + @SerializedName("coupon") + String coupon; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Discounts( + String corporateClientCode, String coupon, Map extraParams) { + this.corporateClientCode = corporateClientCode; + this.coupon = coupon; + this.extraParams = extraParams; } - /** Property phone number. */ - public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { - this.propertyPhoneNumber = propertyPhoneNumber; - return this; + public static Builder builder() { + return new Builder(); } - /** Host's registration date. */ - public Builder setRegisteredAt(Long registeredAt) { - this.registeredAt = registeredAt; - return this; + public static class Builder { + private String corporateClientCode; + + private String coupon; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Discounts build() { + return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Discounts( + this.corporateClientCode, this.coupon, this.extraParams); + } + + /** Corporate client discount code. */ + public Builder setCorporateClientCode(String corporateClientCode) { + this.corporateClientCode = corporateClientCode; + return this; + } + + /** Coupon code. */ + public Builder setCoupon(String coupon) { + this.coupon = coupon; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Address { - /** Required. City, district, suburb, town, or village. */ - @SerializedName("city") - String city; - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - @SerializedName("country") - String country; + public static class ExtraCharge { + /** Amount of the extra charge in cents. */ + @SerializedName("amount") + Long amount; /** * Map of extra parameters for custom features not available in this client library. The @@ -12440,42 +14410,134 @@ public static class Address { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; + /** Type of extra charge. */ + @SerializedName("type") + Type type; + + private ExtraCharge(Long amount, Map extraParams, Type type) { + this.amount = amount; + this.extraParams = extraParams; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private Map extraParams; + + private Type type; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.ExtraCharge build() { + return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.ExtraCharge( + this.amount, this.extraParams, this.type); + } + + /** Amount of the extra charge in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Type of extra charge. */ + public Builder setType( + PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.ExtraCharge.Type type) { + this.type = type; + return this; + } + } + + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("gift_shop") + GIFT_SHOP("gift_shop"), + + @SerializedName("laundry") + LAUNDRY("laundry"), + + @SerializedName("mini_bar") + MINI_BAR("mini_bar"), + + @SerializedName("other") + OTHER("other"), + + @SerializedName("phone") + PHONE("phone"), + + @SerializedName("restaurant") + RESTAURANT("restaurant"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Type(String value) { + this.value = value; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Tax { /** - * Required. Address line 1, such as the street, PO Box, or company name. + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. */ - @SerializedName("line1") - String line1; - - /** Address line 2, such as the apartment, suite, unit, or building. */ - @SerializedName("line2") - String line2; + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Required. ZIP or postal code. */ - @SerializedName("postal_code") - String postalCode; + /** Indicates whether the transaction is tax exempt. */ + @SerializedName("tax_exempt_indicator") + Boolean taxExemptIndicator; - /** - * State, county, province, or region (ISO 3166-2). - */ - @SerializedName("state") - String state; + /** Tax details. */ + @SerializedName("taxes") + List taxes; - private Address( - String city, - String country, + private Tax( Map extraParams, - String line1, - String line2, - String postalCode, - String state) { - this.city = city; - this.country = country; + Boolean taxExemptIndicator, + List + taxes) { this.extraParams = extraParams; - this.line1 = line1; - this.line2 = line2; - this.postalCode = postalCode; - this.state = state; + this.taxExemptIndicator = taxExemptIndicator; + this.taxes = taxes; } public static Builder builder() { @@ -12483,53 +14545,25 @@ public static Builder builder() { } public static class Builder { - private String city; - - private String country; - private Map extraParams; - private String line1; - - private String line2; - - private String postalCode; + private Boolean taxExemptIndicator; - private String state; + private List + taxes; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host.Address build() { - return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host.Address( - this.city, - this.country, - this.extraParams, - this.line1, - this.line2, - this.postalCode, - this.state); - } - - /** Required. City, district, suburb, town, or village. */ - public Builder setCity(String city) { - this.city = city; - return this; - } - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - public Builder setCountry(String country) { - this.country = country; - return this; + public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax build() { + return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax( + this.extraParams, this.taxExemptIndicator, this.taxes); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host.Address#extraParams} for - * the field documentation. + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -12543,8 +14577,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Host.Address#extraParams} for - * the field documentation. + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the + * field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -12554,228 +14588,261 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Required. Address line 1, such as the street, PO Box, or company - * name. - */ - public Builder setLine1(String line1) { - this.line1 = line1; - return this; - } - - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(String line2) { - this.line2 = line2; + /** Indicates whether the transaction is tax exempt. */ + public Builder setTaxExemptIndicator(Boolean taxExemptIndicator) { + this.taxExemptIndicator = taxExemptIndicator; return this; } - /** Required. ZIP or postal code. */ - public Builder setPostalCode(String postalCode) { - this.postalCode = postalCode; + /** + * Add an element to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field + * documentation. + */ + public Builder addTax( + PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax.InnerTax element) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.add(element); return this; } /** - * State, county, province, or region (ISO 3166-2). + * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field + * documentation. */ - public Builder setState(String state) { - this.state = state; + public Builder addAllTax( + List + elements) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.addAll(elements); return this; } } - } - public enum HostType implements ApiRequestParams.EnumParam { - @SerializedName("hostel") - HOSTEL("hostel"), + @Getter + @EqualsAndHashCode(callSuper = false) + public static class InnerTax { + /** Tax amount in cents. */ + @SerializedName("amount") + Long amount; - @SerializedName("hotel") - HOTEL("hotel"), + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - @SerializedName("owner") - OWNER("owner"), + /** Tax rate. */ + @SerializedName("rate") + Long rate; - @SerializedName("rental_agency") - RENTAL_AGENCY("rental_agency"); + /** Type of tax applied. */ + @SerializedName("type") + String type; - @Getter(onMethod_ = {@Override}) - private final String value; + private InnerTax(Long amount, Map extraParams, Long rate, String type) { + this.amount = amount; + this.extraParams = extraParams; + this.rate = rate; + this.type = type; + } - HostType(String value) { - this.value = value; - } - } - } + public static Builder builder() { + return new Builder(); + } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Insurance { - /** Required. Price of the insurance coverage in cents. */ - @SerializedName("amount") - Long amount; + public static class Builder { + private Long amount; - /** Currency of the insurance amount. */ - @SerializedName("currency") - String currency; + private Map extraParams; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private Long rate; - /** Name of the insurance company. */ - @SerializedName("insurance_company_name") - String insuranceCompanyName; + private String type; - /** Required. Type of insurance coverage. */ - @SerializedName("insurance_type") - InsuranceType insuranceType; + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax.InnerTax + build() { + return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax.InnerTax( + this.amount, this.extraParams, this.rate, this.type); + } - private Insurance( - Long amount, - String currency, - Map extraParams, - String insuranceCompanyName, - InsuranceType insuranceType) { - this.amount = amount; - this.currency = currency; - this.extraParams = extraParams; - this.insuranceCompanyName = insuranceCompanyName; - this.insuranceType = insuranceType; - } + /** Tax amount in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - public static Builder builder() { - return new Builder(); + /** Tax rate. */ + public Builder setRate(Long rate) { + this.rate = rate; + return this; + } + + /** Type of tax applied. */ + public Builder setType(String type) { + this.type = type; + return this; + } + } + } } + } + } - public static class Builder { - private Long amount; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Account funding transaction details including sender and beneficiary information. */ + @SerializedName("account_funding") + Object accountFunding; - private String currency; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private Map extraParams; + /** The type of money services transaction. */ + @SerializedName("transaction_type") + ApiRequestParams.EnumParam transactionType; - private String insuranceCompanyName; + private MoneyServices( + Object accountFunding, + Map extraParams, + ApiRequestParams.EnumParam transactionType) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + this.transactionType = transactionType; + } - private InsuranceType insuranceType; + public static Builder builder() { + return new Builder(); + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Insurance build() { - return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Insurance( - this.amount, - this.currency, - this.extraParams, - this.insuranceCompanyName, - this.insuranceType); - } + public static class Builder { + private Object accountFunding; - /** Required. Price of the insurance coverage in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + private Map extraParams; - /** Currency of the insurance amount. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; - } + private ApiRequestParams.EnumParam transactionType; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Insurance#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.MoneyServices build() { + return new PaymentIntentConfirmParams.PaymentDetails.MoneyServices( + this.accountFunding, this.extraParams, this.transactionType); + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Insurance#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding( + PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { + this.accountFunding = accountFunding; + return this; + } - /** Name of the insurance company. */ - public Builder setInsuranceCompanyName(String insuranceCompanyName) { - this.insuranceCompanyName = insuranceCompanyName; - return this; - } + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding(EmptyParam accountFunding) { + this.accountFunding = accountFunding; + return this; + } - /** Required. Type of insurance coverage. */ - public Builder setInsuranceType( - PaymentIntentConfirmParams.PaymentDetails.LodgingData.Insurance.InsuranceType - insuranceType) { - this.insuranceType = insuranceType; - return this; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.MoneyServices#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.put(key, value); + return this; } - public enum InsuranceType implements ApiRequestParams.EnumParam { - @SerializedName("bankruptcy") - BANKRUPTCY("bankruptcy"), - - @SerializedName("cancelation") - CANCELATION("cancelation"), - - @SerializedName("emergency") - EMERGENCY("emergency"), - - @SerializedName("medical") - MEDICAL("medical"); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentConfirmParams.PaymentDetails.MoneyServices#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** The type of money services transaction. */ + public Builder setTransactionType( + PaymentIntentConfirmParams.PaymentDetails.MoneyServices.TransactionType + transactionType) { + this.transactionType = transactionType; + return this; + } - InsuranceType(String value) { - this.value = value; - } + /** The type of money services transaction. */ + public Builder setTransactionType(EmptyParam transactionType) { + this.transactionType = transactionType; + return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Total { - /** Required. Total price of the lodging reservation in cents. */ - @SerializedName("amount") - Long amount; - - /** Cash advances in cents. */ - @SerializedName("cash_advances") - Long cashAdvances; - - /** Currency of the total amount. */ - @SerializedName("currency") - String currency; - - /** Discount details for the lodging. */ - @SerializedName("discounts") - Discounts discounts; + public static class AccountFunding { + /** ID of the Account representing the beneficiary in this account funding transaction. */ + @SerializedName("beneficiary_account") + String beneficiaryAccount; - /** Additional charges for the lodging. */ - @SerializedName("extra_charges") - List extraCharges; + /** Inline identity details for the beneficiary of this account funding transaction. */ + @SerializedName("beneficiary_details") + Object beneficiaryDetails; /** * Map of extra parameters for custom features not available in this client library. The @@ -12787,32 +14854,25 @@ public static class Total { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Prepaid amount in cents. */ - @SerializedName("prepaid_amount") - Long prepaidAmount; + /** ID of the Account representing the sender in this account funding transaction. */ + @SerializedName("sender_account") + String senderAccount; - /** Tax breakdown for the lodging reservation. */ - @SerializedName("tax") - Tax tax; + /** Inline identity details for the sender of this account funding transaction. */ + @SerializedName("sender_details") + Object senderDetails; - private Total( - Long amount, - Long cashAdvances, - String currency, - Discounts discounts, - List - extraCharges, + private AccountFunding( + String beneficiaryAccount, + Object beneficiaryDetails, Map extraParams, - Long prepaidAmount, - Tax tax) { - this.amount = amount; - this.cashAdvances = cashAdvances; - this.currency = currency; - this.discounts = discounts; - this.extraCharges = extraCharges; + String senderAccount, + Object senderDetails) { + this.beneficiaryAccount = beneficiaryAccount; + this.beneficiaryDetails = beneficiaryDetails; this.extraParams = extraParams; - this.prepaidAmount = prepaidAmount; - this.tax = tax; + this.senderAccount = senderAccount; + this.senderDetails = senderDetails; } public static Builder builder() { @@ -12820,89 +14880,44 @@ public static Builder builder() { } public static class Builder { - private Long amount; - - private Long cashAdvances; - - private String currency; + private String beneficiaryAccount; - private Discounts discounts; - - private List - extraCharges; + private Object beneficiaryDetails; private Map extraParams; - private Long prepaidAmount; - - private Tax tax; - - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total build() { - return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total( - this.amount, - this.cashAdvances, - this.currency, - this.discounts, - this.extraCharges, - this.extraParams, - this.prepaidAmount, - this.tax); - } - - /** Required. Total price of the lodging reservation in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } - - /** Cash advances in cents. */ - public Builder setCashAdvances(Long cashAdvances) { - this.cashAdvances = cashAdvances; - return this; - } + private String senderAccount; - /** Currency of the total amount. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; + private Object senderDetails; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding build() { + return new PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding( + this.beneficiaryAccount, + this.beneficiaryDetails, + this.extraParams, + this.senderAccount, + this.senderDetails); } - /** Discount details for the lodging. */ - public Builder setDiscounts( - PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Discounts discounts) { - this.discounts = discounts; + /** ID of the Account representing the beneficiary in this account funding transaction. */ + public Builder setBeneficiaryAccount(String beneficiaryAccount) { + this.beneficiaryAccount = beneficiaryAccount; return this; } - /** - * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total#extraCharges} for the field - * documentation. - */ - public Builder addExtraCharge( - PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.ExtraCharge element) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.add(element); + /** Inline identity details for the beneficiary of this account funding transaction. */ + public Builder setBeneficiaryDetails( + PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails + beneficiaryDetails) { + this.beneficiaryDetails = beneficiaryDetails; return this; } - /** - * Add all elements to `extraCharges` list. A list is initialized for the first - * `add/addAll` call, and subsequent calls adds additional elements to the original list. - * See {@link PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total#extraCharges} - * for the field documentation. - */ - public Builder addAllExtraCharge( - List - elements) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.addAll(elements); + /** Inline identity details for the beneficiary of this account funding transaction. */ + public Builder setBeneficiaryDetails(EmptyParam beneficiaryDetails) { + this.beneficiaryDetails = beneficiaryDetails; return this; } @@ -12910,8 +14925,8 @@ public Builder addAllExtraCharge( * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total#extraParams} for the field - * documentation. + * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -12925,8 +14940,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total#extraParams} for the field - * documentation. + * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -12936,30 +14951,41 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Prepaid amount in cents. */ - public Builder setPrepaidAmount(Long prepaidAmount) { - this.prepaidAmount = prepaidAmount; + /** ID of the Account representing the sender in this account funding transaction. */ + public Builder setSenderAccount(String senderAccount) { + this.senderAccount = senderAccount; return this; } - /** Tax breakdown for the lodging reservation. */ - public Builder setTax( - PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax tax) { - this.tax = tax; + /** Inline identity details for the sender of this account funding transaction. */ + public Builder setSenderDetails( + PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + senderDetails) { + this.senderDetails = senderDetails; + return this; + } + + /** Inline identity details for the sender of this account funding transaction. */ + public Builder setSenderDetails(EmptyParam senderDetails) { + this.senderDetails = senderDetails; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Discounts { - /** Corporate client discount code. */ - @SerializedName("corporate_client_code") - String corporateClientCode; + public static class BeneficiaryDetails { + /** Address. */ + @SerializedName("address") + Address address; - /** Coupon code. */ - @SerializedName("coupon") - String coupon; + /** Date of birth. */ + @SerializedName("date_of_birth") + DateOfBirth dateOfBirth; + + /** Email address. */ + @SerializedName("email") + String email; /** * Map of extra parameters for custom features not available in this client library. The @@ -12971,11 +14997,27 @@ public static class Discounts { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private Discounts( - String corporateClientCode, String coupon, Map extraParams) { - this.corporateClientCode = corporateClientCode; - this.coupon = coupon; + /** Full name. */ + @SerializedName("name") + String name; + + /** Phone number. */ + @SerializedName("phone") + String phone; + + private BeneficiaryDetails( + Address address, + DateOfBirth dateOfBirth, + String email, + Map extraParams, + String name, + String phone) { + this.address = address; + this.dateOfBirth = dateOfBirth; + this.email = email; this.extraParams = extraParams; + this.name = name; + this.phone = phone; } public static Builder builder() { @@ -12983,27 +15025,53 @@ public static Builder builder() { } public static class Builder { - private String corporateClientCode; + private Address address; - private String coupon; + private DateOfBirth dateOfBirth; + + private String email; private Map extraParams; + private String name; + + private String phone; + /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Discounts build() { - return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Discounts( - this.corporateClientCode, this.coupon, this.extraParams); + public PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails + build() { + return new PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails( + this.address, + this.dateOfBirth, + this.email, + this.extraParams, + this.name, + this.phone); } - /** Corporate client discount code. */ - public Builder setCorporateClientCode(String corporateClientCode) { - this.corporateClientCode = corporateClientCode; + /** Address. */ + public Builder setAddress( + PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.Address + address) { + this.address = address; return this; } - /** Coupon code. */ - public Builder setCoupon(String coupon) { - this.coupon = coupon; + /** Date of birth. */ + public Builder setDateOfBirth( + PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.DateOfBirth + dateOfBirth) { + this.dateOfBirth = dateOfBirth; + return this; + } + + /** Email address. */ + public Builder setEmail(String email) { + this.email = email; return this; } @@ -13011,7 +15079,7 @@ public Builder setCoupon(String coupon) { * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} + * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails#extraParams} * for the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -13026,7 +15094,7 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} + * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails#extraParams} * for the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -13036,128 +15104,308 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } + + /** Full name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** Phone number. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class ExtraCharge { - /** Amount of the extra charge in cents. */ - @SerializedName("amount") - Long amount; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Address { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + String city; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + String country; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Address line 1, such as the street, PO Box, or company name. */ + @SerializedName("line1") + String line1; + + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; + + /** ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; + + private Address( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String city; + + private String country; + + private Map extraParams; + + private String line1; + + private String line2; + + private String postalCode; + + private String state; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.Address + build() { + return new PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } + + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.Address#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.Address#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } - /** Type of extra charge. */ - @SerializedName("type") - Type type; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } - private ExtraCharge(Long amount, Map extraParams, Type type) { - this.amount = amount; - this.extraParams = extraParams; - this.type = type; - } + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - public static Builder builder() { - return new Builder(); + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + } } - public static class Builder { - private Long amount; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class DateOfBirth { + /** Required. Day of birth, between 1 and 31. */ + @SerializedName("day") + Long day; - private Map extraParams; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private Type type; + /** Required. Month of birth, between 1 and 12. */ + @SerializedName("month") + Long month; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.ExtraCharge build() { - return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.ExtraCharge( - this.amount, this.extraParams, this.type); - } + /** Required. Four-digit year of birth. */ + @SerializedName("year") + Long year; - /** Amount of the extra charge in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; + private DateOfBirth(Long day, Map extraParams, Long month, Long year) { + this.day = day; + this.extraParams = extraParams; + this.month = month; + this.year = year; } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; + public static Builder builder() { + return new Builder(); } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + public static class Builder { + private Long day; - /** Type of extra charge. */ - public Builder setType( - PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.ExtraCharge.Type type) { - this.type = type; - return this; - } - } + private Map extraParams; - public enum Type implements ApiRequestParams.EnumParam { - @SerializedName("gift_shop") - GIFT_SHOP("gift_shop"), + private Long month; - @SerializedName("laundry") - LAUNDRY("laundry"), + private Long year; - @SerializedName("mini_bar") - MINI_BAR("mini_bar"), + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.DateOfBirth + build() { + return new PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.DateOfBirth( + this.day, this.extraParams, this.month, this.year); + } - @SerializedName("other") - OTHER("other"), + /** Required. Day of birth, between 1 and 31. */ + public Builder setDay(Long day) { + this.day = day; + return this; + } - @SerializedName("phone") - PHONE("phone"), + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - @SerializedName("restaurant") - RESTAURANT("restaurant"); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** Required. Month of birth, between 1 and 12. */ + public Builder setMonth(Long month) { + this.month = month; + return this; + } - Type(String value) { - this.value = value; + /** Required. Four-digit year of birth. */ + public Builder setYear(Long year) { + this.year = year; + return this; + } } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Tax { + public static class SenderDetails { + /** Address. */ + @SerializedName("address") + Address address; + + /** Date of birth. */ + @SerializedName("date_of_birth") + DateOfBirth dateOfBirth; + + /** Email address. */ + @SerializedName("email") + String email; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -13168,22 +15416,27 @@ public static class Tax { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Indicates whether the transaction is tax exempt. */ - @SerializedName("tax_exempt_indicator") - Boolean taxExemptIndicator; + /** Full name. */ + @SerializedName("name") + String name; - /** Tax details. */ - @SerializedName("taxes") - List taxes; + /** Phone number. */ + @SerializedName("phone") + String phone; - private Tax( + private SenderDetails( + Address address, + DateOfBirth dateOfBirth, + String email, Map extraParams, - Boolean taxExemptIndicator, - List - taxes) { + String name, + String phone) { + this.address = address; + this.dateOfBirth = dateOfBirth; + this.email = email; this.extraParams = extraParams; - this.taxExemptIndicator = taxExemptIndicator; - this.taxes = taxes; + this.name = name; + this.phone = phone; } public static Builder builder() { @@ -13191,25 +15444,62 @@ public static Builder builder() { } public static class Builder { + private Address address; + + private DateOfBirth dateOfBirth; + + private String email; + private Map extraParams; - private Boolean taxExemptIndicator; + private String name; - private List - taxes; + private String phone; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax build() { - return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax( - this.extraParams, this.taxExemptIndicator, this.taxes); + public PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails + build() { + return new PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails( + this.address, + this.dateOfBirth, + this.email, + this.extraParams, + this.name, + this.phone); + } + + /** Address. */ + public Builder setAddress( + PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + .Address + address) { + this.address = address; + return this; + } + + /** Date of birth. */ + public Builder setDateOfBirth( + PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + .DateOfBirth + dateOfBirth) { + this.dateOfBirth = dateOfBirth; + return this; + } + + /** Email address. */ + public Builder setEmail(String email) { + this.email = email; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the - * field documentation. + * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -13223,8 +15513,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the - * field documentation. + * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -13234,50 +15524,32 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Indicates whether the transaction is tax exempt. */ - public Builder setTaxExemptIndicator(Boolean taxExemptIndicator) { - this.taxExemptIndicator = taxExemptIndicator; - return this; - } - - /** - * Add an element to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addTax( - PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax.InnerTax element) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.add(element); + /** Full name. */ + public Builder setName(String name) { + this.name = name; return this; } - /** - * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addAllTax( - List - elements) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.addAll(elements); + /** Phone number. */ + public Builder setPhone(String phone) { + this.phone = phone; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class InnerTax { - /** Tax amount in cents. */ - @SerializedName("amount") - Long amount; + public static class Address { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + String city; + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + String country; /** * Map of extra parameters for custom features not available in this client library. The @@ -13289,19 +15561,40 @@ public static class InnerTax { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Tax rate. */ - @SerializedName("rate") - Long rate; + /** Address line 1, such as the street, PO Box, or company name. */ + @SerializedName("line1") + String line1; - /** Type of tax applied. */ - @SerializedName("type") - String type; + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; - private InnerTax(Long amount, Map extraParams, Long rate, String type) { - this.amount = amount; + /** ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; + + private Address( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; this.extraParams = extraParams; - this.rate = rate; - this.type = type; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; } public static Builder builder() { @@ -13309,24 +15602,47 @@ public static Builder builder() { } public static class Builder { - private Long amount; + private String city; + + private String country; private Map extraParams; - private Long rate; + private String line1; - private String type; + private String line2; + + private String postalCode; + + private String state; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax.InnerTax + public PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.Address build() { - return new PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax.InnerTax( - this.amount, this.extraParams, this.rate, this.type); + return new PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); } - /** Tax amount in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; return this; } @@ -13334,7 +15650,7 @@ public Builder setAmount(Long amount) { * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} + * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.Address#extraParams} * for the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -13349,7 +15665,7 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the * first `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} + * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.Address#extraParams} * for the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -13360,175 +15676,136 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Tax rate. */ - public Builder setRate(Long rate) { - this.rate = rate; + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(String line1) { + this.line1 = line1; return this; } - /** Type of tax applied. */ - public Builder setType(String type) { - this.type = type; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; return this; } - } - } - } - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class MoneyServices { - /** Account funding transaction details including sender and beneficiary information. */ - @SerializedName("account_funding") - Object accountFunding; - - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) - * name in this param object. Effectively, this map is flattened to its parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; - - /** The type of money services transaction. */ - @SerializedName("transaction_type") - TransactionType transactionType; - - private MoneyServices( - Object accountFunding, Map extraParams, TransactionType transactionType) { - this.accountFunding = accountFunding; - this.extraParams = extraParams; - this.transactionType = transactionType; - } - public static Builder builder() { - return new Builder(); - } + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - public static class Builder { - private Object accountFunding; + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + } + } - private Map extraParams; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class DateOfBirth { + /** Required. Day of birth, between 1 and 31. */ + @SerializedName("day") + Long day; - private TransactionType transactionType; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.MoneyServices build() { - return new PaymentIntentConfirmParams.PaymentDetails.MoneyServices( - this.accountFunding, this.extraParams, this.transactionType); - } + /** Required. Month of birth, between 1 and 12. */ + @SerializedName("month") + Long month; - /** Account funding transaction details including sender and beneficiary information. */ - public Builder setAccountFunding( - PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { - this.accountFunding = accountFunding; - return this; - } + /** Required. Four-digit year of birth. */ + @SerializedName("year") + Long year; - /** Account funding transaction details including sender and beneficiary information. */ - public Builder setAccountFunding(EmptyParam accountFunding) { - this.accountFunding = accountFunding; - return this; - } + private DateOfBirth(Long day, Map extraParams, Long month, Long year) { + this.day = day; + this.extraParams = extraParams; + this.month = month; + this.year = year; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.MoneyServices#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + public static Builder builder() { + return new Builder(); + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentConfirmParams.PaymentDetails.MoneyServices#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + public static class Builder { + private Long day; - /** The type of money services transaction. */ - public Builder setTransactionType( - PaymentIntentConfirmParams.PaymentDetails.MoneyServices.TransactionType - transactionType) { - this.transactionType = transactionType; - return this; - } - } + private Map extraParams; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class AccountFunding { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private Long month; - private AccountFunding(Map extraParams) { - this.extraParams = extraParams; - } + private Long year; - public static Builder builder() { - return new Builder(); - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.DateOfBirth + build() { + return new PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.DateOfBirth(this.day, this.extraParams, this.month, this.year); + } - public static class Builder { - private Map extraParams; + /** Required. Day of birth, between 1 and 31. */ + public Builder setDay(Long day) { + this.day = day; + return this; + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding build() { - return new PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding( - this.extraParams); - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** Required. Month of birth, between 1 and 12. */ + public Builder setMonth(Long month) { + this.month = month; + return this; + } + + /** Required. Four-digit year of birth. */ + public Builder setYear(Long year) { + this.year = year; + return this; + } } - this.extraParams.putAll(map); - return this; } } } @@ -26481,53 +28758,604 @@ public static class AccountFunding { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private AccountFunding(Map extraParams) { + /** Details for a liquid asset (crypto or security) funding transaction. */ + @SerializedName("liquid_asset") + Object liquidAsset; + + /** Details for a wallet funding transaction. */ + @SerializedName("wallet") + Wallet wallet; + + private AccountFunding( + Map extraParams, Object liquidAsset, Wallet wallet) { this.extraParams = extraParams; + this.liquidAsset = liquidAsset; + this.wallet = wallet; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Object liquidAsset; + + private Wallet wallet; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding(this.extraParams, this.liquidAsset, this.wallet); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Details for a liquid asset (crypto or security) funding transaction. */ + public Builder setLiquidAsset( + PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + .AccountFunding.LiquidAsset + liquidAsset) { + this.liquidAsset = liquidAsset; + return this; + } + + /** Details for a liquid asset (crypto or security) funding transaction. */ + public Builder setLiquidAsset(EmptyParam liquidAsset) { + this.liquidAsset = liquidAsset; + return this; + } + + /** Details for a wallet funding transaction. */ + public Builder setWallet( + PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + .AccountFunding.Wallet + wallet) { + this.wallet = wallet; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class LiquidAsset { + /** Details for a cryptocurrency liquid asset funding transaction. */ + @SerializedName("crypto") + Crypto crypto; + + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if the + * key is a root-level field (serialized) name in this param object. Effectively, this + * map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Details for a security liquid asset funding transaction. */ + @SerializedName("security") + Security security; + + private LiquidAsset( + Crypto crypto, Map extraParams, Security security) { + this.crypto = crypto; + this.extraParams = extraParams; + this.security = security; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Crypto crypto; + + private Map extraParams; + + private Security security; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset( + this.crypto, this.extraParams, this.security); + } + + /** Details for a cryptocurrency liquid asset funding transaction. */ + public Builder setCrypto( + PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Crypto + crypto) { + this.crypto = crypto; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Details for a security liquid asset funding transaction. */ + public Builder setSecurity( + PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Security + security) { + this.security = security; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Crypto { + /** The cryptocurrency currency code (e.g. BTC, ETH). */ + @SerializedName("currency_code") + String currencyCode; + + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Crypto(String currencyCode, Map extraParams) { + this.currencyCode = currencyCode; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String currencyCode; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Crypto + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Crypto( + this.currencyCode, this.extraParams); + } + + /** The cryptocurrency currency code (e.g. BTC, ETH). */ + public Builder setCurrencyCode(String currencyCode) { + this.currencyCode = currencyCode; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Crypto#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Crypto#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Security { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The security's ticker symbol (e.g. AAPL). */ + @SerializedName("ticker_symbol") + String tickerSymbol; + + private Security(Map extraParams, String tickerSymbol) { + this.extraParams = extraParams; + this.tickerSymbol = tickerSymbol; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String tickerSymbol; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Security + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Security( + this.extraParams, this.tickerSymbol); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Security#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Security#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The security's ticker symbol (e.g. AAPL). */ + public Builder setTickerSymbol(String tickerSymbol) { + this.tickerSymbol = tickerSymbol; + return this; + } + } + } } - public static Builder builder() { - return new Builder(); - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Wallet { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if the + * key is a root-level field (serialized) name in this param object. Effectively, this + * map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Details for a staged purchase. */ + @SerializedName("staged_purchase") + Object stagedPurchase; + + private Wallet(Map extraParams, Object stagedPurchase) { + this.extraParams = extraParams; + this.stagedPurchase = stagedPurchase; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Object stagedPurchase; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet(this.extraParams, this.stagedPurchase); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Details for a staged purchase. */ + public Builder setStagedPurchase( + PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase + stagedPurchase) { + this.stagedPurchase = stagedPurchase; + return this; + } + + /** Details for a staged purchase. */ + public Builder setStagedPurchase(EmptyParam stagedPurchase) { + this.stagedPurchase = stagedPurchase; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class StagedPurchase { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The merchant where the staged wallet purchase is made. */ + @SerializedName("merchant") + Merchant merchant; + + private StagedPurchase(Map extraParams, Merchant merchant) { + this.extraParams = extraParams; + this.merchant = merchant; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Merchant merchant; - public static class Builder { - private Map extraParams; + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase( + this.extraParams, this.merchant); + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails - .MoneyServices.AccountFunding - build() { - return new PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails - .MoneyServices.AccountFunding(this.extraParams); - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The merchant where the staged wallet purchase is made. */ + public Builder setMerchant( + PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant + merchant) { + this.merchant = merchant; + return this; + } } - this.extraParams.put(key, value); - return this; - } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the - * first `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Merchant { + /** + * Map of extra parameters for custom features not available in this client + * library. The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The merchant category code of the merchant. */ + @SerializedName("mcc") + String mcc; + + /** The merchant's name. */ + @SerializedName("name") + String name; + + private Merchant(Map extraParams, String mcc, String name) { + this.extraParams = extraParams; + this.mcc = mcc; + this.name = name; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String mcc; + + private String name; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant( + this.extraParams, this.mcc, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for + * the first `put/putAll` call, and subsequent calls add additional key/value + * pairs to the original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The merchant category code of the merchant. */ + public Builder setMcc(String mcc) { + this.mcc = mcc; + return this; + } + + /** The merchant's name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + } } - this.extraParams.putAll(map); - return this; } } } @@ -27935,8 +30763,19 @@ public static class AccountFunding { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private AccountFunding(Map extraParams) { + /** Details for a liquid asset (crypto or security) funding transaction. */ + @SerializedName("liquid_asset") + Object liquidAsset; + + /** Details for a wallet funding transaction. */ + @SerializedName("wallet") + Wallet wallet; + + private AccountFunding( + Map extraParams, Object liquidAsset, Wallet wallet) { this.extraParams = extraParams; + this.liquidAsset = liquidAsset; + this.wallet = wallet; } public static Builder builder() { @@ -27946,12 +30785,17 @@ public static Builder builder() { public static class Builder { private Map extraParams; + private Object liquidAsset; + + private Wallet wallet; + /** Finalize and obtain parameter instance from this builder. */ public PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails .MoneyServices.AccountFunding build() { return new PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent - .PaymentDetails.MoneyServices.AccountFunding(this.extraParams); + .PaymentDetails.MoneyServices.AccountFunding( + this.extraParams, this.liquidAsset, this.wallet); } /** @@ -27983,6 +30827,544 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } + + /** Details for a liquid asset (crypto or security) funding transaction. */ + public Builder setLiquidAsset( + PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset + liquidAsset) { + this.liquidAsset = liquidAsset; + return this; + } + + /** Details for a liquid asset (crypto or security) funding transaction. */ + public Builder setLiquidAsset(EmptyParam liquidAsset) { + this.liquidAsset = liquidAsset; + return this; + } + + /** Details for a wallet funding transaction. */ + public Builder setWallet( + PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet + wallet) { + this.wallet = wallet; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class LiquidAsset { + /** Details for a cryptocurrency liquid asset funding transaction. */ + @SerializedName("crypto") + Crypto crypto; + + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if the + * key is a root-level field (serialized) name in this param object. Effectively, this + * map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Details for a security liquid asset funding transaction. */ + @SerializedName("security") + Security security; + + private LiquidAsset( + Crypto crypto, Map extraParams, Security security) { + this.crypto = crypto; + this.extraParams = extraParams; + this.security = security; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Crypto crypto; + + private Map extraParams; + + private Security security; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.LiquidAsset( + this.crypto, this.extraParams, this.security); + } + + /** Details for a cryptocurrency liquid asset funding transaction. */ + public Builder setCrypto( + PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Crypto + crypto) { + this.crypto = crypto; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Details for a security liquid asset funding transaction. */ + public Builder setSecurity( + PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Security + security) { + this.security = security; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Crypto { + /** The cryptocurrency currency code (e.g. BTC, ETH). */ + @SerializedName("currency_code") + String currencyCode; + + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Crypto(String currencyCode, Map extraParams) { + this.currencyCode = currencyCode; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String currencyCode; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Crypto + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Crypto( + this.currencyCode, this.extraParams); + } + + /** The cryptocurrency currency code (e.g. BTC, ETH). */ + public Builder setCurrencyCode(String currencyCode) { + this.currencyCode = currencyCode; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Crypto#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Crypto#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Security { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The security's ticker symbol (e.g. AAPL). */ + @SerializedName("ticker_symbol") + String tickerSymbol; + + private Security(Map extraParams, String tickerSymbol) { + this.extraParams = extraParams; + this.tickerSymbol = tickerSymbol; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String tickerSymbol; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Security + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Security( + this.extraParams, this.tickerSymbol); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Security#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Security#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The security's ticker symbol (e.g. AAPL). */ + public Builder setTickerSymbol(String tickerSymbol) { + this.tickerSymbol = tickerSymbol; + return this; + } + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Wallet { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if the + * key is a root-level field (serialized) name in this param object. Effectively, this + * map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Details for a staged purchase. */ + @SerializedName("staged_purchase") + Object stagedPurchase; + + private Wallet(Map extraParams, Object stagedPurchase) { + this.extraParams = extraParams; + this.stagedPurchase = stagedPurchase; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Object stagedPurchase; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.Wallet( + this.extraParams, this.stagedPurchase); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Details for a staged purchase. */ + public Builder setStagedPurchase( + PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase + stagedPurchase) { + this.stagedPurchase = stagedPurchase; + return this; + } + + /** Details for a staged purchase. */ + public Builder setStagedPurchase(EmptyParam stagedPurchase) { + this.stagedPurchase = stagedPurchase; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class StagedPurchase { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The merchant where the staged wallet purchase is made. */ + @SerializedName("merchant") + Merchant merchant; + + private StagedPurchase(Map extraParams, Merchant merchant) { + this.extraParams = extraParams; + this.merchant = merchant; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Merchant merchant; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase( + this.extraParams, this.merchant); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The merchant where the staged wallet purchase is made. */ + public Builder setMerchant( + PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant + merchant) { + this.merchant = merchant; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Merchant { + /** + * Map of extra parameters for custom features not available in this client + * library. The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The merchant category code of the merchant. */ + @SerializedName("mcc") + String mcc; + + /** The merchant's name. */ + @SerializedName("name") + String name; + + private Merchant(Map extraParams, String mcc, String name) { + this.extraParams = extraParams; + this.mcc = mcc; + this.name = name; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String mcc; + + private String name; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase + .Merchant + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase + .Merchant(this.extraParams, this.mcc, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for + * the first `put/putAll` call, and subsequent calls add additional key/value + * pairs to the original map. See {@link + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The merchant category code of the merchant. */ + public Builder setMcc(String mcc) { + this.mcc = mcc; + return this; + } + + /** The merchant's name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + } + } + } } } } diff --git a/src/main/java/com/stripe/param/PaymentIntentCreateParams.java b/src/main/java/com/stripe/param/PaymentIntentCreateParams.java index 917d1345c3a..8ed15015aed 100644 --- a/src/main/java/com/stripe/param/PaymentIntentCreateParams.java +++ b/src/main/java/com/stripe/param/PaymentIntentCreateParams.java @@ -1553,6 +1553,13 @@ public static class LineItem { @SerializedName("quantity") Long quantity; + /** + * The number of decimal places implied in the quantity. For example, if quantity is 10000 and + * quantity_precision is 2, the actual quantity is 100.00. Defaults to 0 if not provided. + */ + @SerializedName("quantity_precision") + Long quantityPrecision; + /** Contains information about the tax on the item. */ @SerializedName("tax") Tax tax; @@ -1576,6 +1583,7 @@ private LineItem( String productCode, String productName, Long quantity, + Long quantityPrecision, Tax tax, Long unitCost, String unitOfMeasure) { @@ -1585,6 +1593,7 @@ private LineItem( this.productCode = productCode; this.productName = productName; this.quantity = quantity; + this.quantityPrecision = quantityPrecision; this.tax = tax; this.unitCost = unitCost; this.unitOfMeasure = unitOfMeasure; @@ -1607,6 +1616,8 @@ public static class Builder { private Long quantity; + private Long quantityPrecision; + private Tax tax; private Long unitCost; @@ -1622,6 +1633,7 @@ public PaymentIntentCreateParams.AmountDetails.LineItem build() { this.productCode, this.productName, this.quantity, + this.quantityPrecision, this.tax, this.unitCost, this.unitOfMeasure); @@ -1706,6 +1718,16 @@ public Builder setQuantity(Long quantity) { return this; } + /** + * The number of decimal places implied in the quantity. For example, if quantity is 10000 + * and quantity_precision is 2, the actual quantity is 100.00. Defaults to 0 if not + * provided. + */ + public Builder setQuantityPrecision(Long quantityPrecision) { + this.quantityPrecision = quantityPrecision; + return this; + } + /** Contains information about the tax on the item. */ public Builder setTax(PaymentIntentCreateParams.AmountDetails.LineItem.Tax tax) { this.tax = tax; @@ -1896,9 +1918,14 @@ public static class Card { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private Card(String commodityCode, Map extraParams) { + /** Fleet data for this line item. */ + @SerializedName("fleet_data") + FleetData fleetData; + + private Card(String commodityCode, Map extraParams, FleetData fleetData) { this.commodityCode = commodityCode; this.extraParams = extraParams; + this.fleetData = fleetData; } public static Builder builder() { @@ -1910,11 +1937,13 @@ public static class Builder { private Map extraParams; + private FleetData fleetData; + /** Finalize and obtain parameter instance from this builder. */ public PaymentIntentCreateParams.AmountDetails.LineItem.PaymentMethodOptions.Card build() { return new PaymentIntentCreateParams.AmountDetails.LineItem.PaymentMethodOptions.Card( - this.commodityCode, this.extraParams); + this.commodityCode, this.extraParams, this.fleetData); } /** @@ -1955,6 +1984,266 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } + + /** Fleet data for this line item. */ + public Builder setFleetData( + PaymentIntentCreateParams.AmountDetails.LineItem.PaymentMethodOptions.Card.FleetData + fleetData) { + this.fleetData = fleetData; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class FleetData { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Required. The type of product being purchased at this line item. */ + @SerializedName("product_type") + ProductType productType; + + /** The type of service received at the acceptor location. */ + @SerializedName("service_type") + ServiceType serviceType; + + private FleetData( + Map extraParams, ProductType productType, ServiceType serviceType) { + this.extraParams = extraParams; + this.productType = productType; + this.serviceType = serviceType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private ProductType productType; + + private ServiceType serviceType; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.AmountDetails.LineItem.PaymentMethodOptions.Card + .FleetData + build() { + return new PaymentIntentCreateParams.AmountDetails.LineItem.PaymentMethodOptions + .Card.FleetData(this.extraParams, this.productType, this.serviceType); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.AmountDetails.LineItem.PaymentMethodOptions.Card.FleetData#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.AmountDetails.LineItem.PaymentMethodOptions.Card.FleetData#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. The type of product being purchased at this line item. + */ + public Builder setProductType( + PaymentIntentCreateParams.AmountDetails.LineItem.PaymentMethodOptions.Card + .FleetData.ProductType + productType) { + this.productType = productType; + return this; + } + + /** The type of service received at the acceptor location. */ + public Builder setServiceType( + PaymentIntentCreateParams.AmountDetails.LineItem.PaymentMethodOptions.Card + .FleetData.ServiceType + serviceType) { + this.serviceType = serviceType; + return this; + } + } + + public enum ProductType implements ApiRequestParams.EnumParam { + @SerializedName("air_conditioning_service") + AIR_CONDITIONING_SERVICE("air_conditioning_service"), + + @SerializedName("alcohol") + ALCOHOL("alcohol"), + + @SerializedName("aviation_fuel_premium") + AVIATION_FUEL_PREMIUM("aviation_fuel_premium"), + + @SerializedName("aviation_fuel_regular") + AVIATION_FUEL_REGULAR("aviation_fuel_regular"), + + @SerializedName("car_care_detailing") + CAR_CARE_DETAILING("car_care_detailing"), + + @SerializedName("compressed_natural_gas") + COMPRESSED_NATURAL_GAS("compressed_natural_gas"), + + @SerializedName("deli") + DELI("deli"), + + @SerializedName("food_service") + FOOD_SERVICE("food_service"), + + @SerializedName("green_gasoline_mid_plus") + GREEN_GASOLINE_MID_PLUS("green_gasoline_mid_plus"), + + @SerializedName("green_gasoline_premium_super") + GREEN_GASOLINE_PREMIUM_SUPER("green_gasoline_premium_super"), + + @SerializedName("green_gasoline_regular") + GREEN_GASOLINE_REGULAR("green_gasoline_regular"), + + @SerializedName("grocery") + GROCERY("grocery"), + + @SerializedName("liquid_natural_gas") + LIQUID_NATURAL_GAS("liquid_natural_gas"), + + @SerializedName("liquid_propane_gas") + LIQUID_PROPANE_GAS("liquid_propane_gas"), + + @SerializedName("lodging") + LODGING("lodging"), + + @SerializedName("marine_diesel") + MARINE_DIESEL("marine_diesel"), + + @SerializedName("marine_fuel") + MARINE_FUEL("marine_fuel"), + + @SerializedName("merchandise") + MERCHANDISE("merchandise"), + + @SerializedName("mid_plus") + MID_PLUS("mid_plus"), + + @SerializedName("mid_plus_ethanol") + MID_PLUS_ETHANOL("mid_plus_ethanol"), + + @SerializedName("miscellaneous_aviation_products_services") + MISCELLANEOUS_AVIATION_PRODUCTS_SERVICES("miscellaneous_aviation_products_services"), + + @SerializedName("miscellaneous_fuel") + MISCELLANEOUS_FUEL("miscellaneous_fuel"), + + @SerializedName("miscellaneous_marine_products_services") + MISCELLANEOUS_MARINE_PRODUCTS_SERVICES("miscellaneous_marine_products_services"), + + @SerializedName("miscellaneous_vehicle_products_services") + MISCELLANEOUS_VEHICLE_PRODUCTS_SERVICES("miscellaneous_vehicle_products_services"), + + @SerializedName("packaged_beverage") + PACKAGED_BEVERAGE("packaged_beverage"), + + @SerializedName("premium_diesel") + PREMIUM_DIESEL("premium_diesel"), + + @SerializedName("premium_super") + PREMIUM_SUPER("premium_super"), + + @SerializedName("premium_super_ethanol") + PREMIUM_SUPER_ETHANOL("premium_super_ethanol"), + + @SerializedName("preventative_maintenance") + PREVENTATIVE_MAINTENANCE("preventative_maintenance"), + + @SerializedName("regular") + REGULAR("regular"), + + @SerializedName("regular_diesel") + REGULAR_DIESEL("regular_diesel"), + + @SerializedName("regular_ethanol") + REGULAR_ETHANOL("regular_ethanol"), + + @SerializedName("repairs") + REPAIRS("repairs"), + + @SerializedName("self_service_car_wash") + SELF_SERVICE_CAR_WASH("self_service_car_wash"), + + @SerializedName("shower") + SHOWER("shower"), + + @SerializedName("store_service") + STORE_SERVICE("store_service"), + + @SerializedName("tobacco") + TOBACCO("tobacco"), + + @SerializedName("vehicle_accessories") + VEHICLE_ACCESSORIES("vehicle_accessories"), + + @SerializedName("vehicle_parking") + VEHICLE_PARKING("vehicle_parking"), + + @SerializedName("vehicle_parts") + VEHICLE_PARTS("vehicle_parts"), + + @SerializedName("wash_out") + WASH_OUT("wash_out"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ProductType(String value) { + this.value = value; + } + } + + public enum ServiceType implements ApiRequestParams.EnumParam { + @SerializedName("full_service") + FULL_SERVICE("full_service"), + + @SerializedName("high_speed_diesel") + HIGH_SPEED_DIESEL("high_speed_diesel"), + + @SerializedName("non_fuel_only") + NON_FUEL_ONLY("non_fuel_only"), + + @SerializedName("self_service") + SELF_SERVICE("self_service"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ServiceType(String value) { + this.value = value; + } + } } } @@ -3514,6 +3803,10 @@ public static class PaymentDetails { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; + /** Fleet data for this PaymentIntent. */ + @SerializedName("fleet_data") + Object fleetData; + /** Flight reservation details for this PaymentIntent. */ @SerializedName("flight") Flight flight; @@ -3556,6 +3849,7 @@ private PaymentDetails( Object customerReference, EventDetails eventDetails, Map extraParams, + Object fleetData, Flight flight, Object flightData, Lodging lodging, @@ -3569,6 +3863,7 @@ private PaymentDetails( this.customerReference = customerReference; this.eventDetails = eventDetails; this.extraParams = extraParams; + this.fleetData = fleetData; this.flight = flight; this.flightData = flightData; this.lodging = lodging; @@ -3595,6 +3890,8 @@ public static class Builder { private Map extraParams; + private Object fleetData; + private Flight flight; private Object flightData; @@ -3618,6 +3915,7 @@ public PaymentIntentCreateParams.PaymentDetails build() { this.customerReference, this.eventDetails, this.extraParams, + this.fleetData, this.flight, this.flightData, this.lodging, @@ -3742,6 +4040,49 @@ public Builder putAllExtraParam(Map map) { return this; } + /** + * Add an element to `fleetData` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails#fleetData} for the field documentation. + */ + @SuppressWarnings("unchecked") + public Builder addFleetData(PaymentIntentCreateParams.PaymentDetails.FleetData element) { + if (this.fleetData == null || this.fleetData instanceof EmptyParam) { + this.fleetData = new ArrayList(); + } + ((List) this.fleetData).add(element); + return this; + } + + /** + * Add all elements to `fleetData` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails#fleetData} for the field documentation. + */ + @SuppressWarnings("unchecked") + public Builder addAllFleetData( + List elements) { + if (this.fleetData == null || this.fleetData instanceof EmptyParam) { + this.fleetData = new ArrayList(); + } + ((List) this.fleetData) + .addAll(elements); + return this; + } + + /** Fleet data for this PaymentIntent. */ + public Builder setFleetData(EmptyParam fleetData) { + this.fleetData = fleetData; + return this; + } + + /** Fleet data for this PaymentIntent. */ + public Builder setFleetData( + List fleetData) { + this.fleetData = fleetData; + return this; + } + /** Flight reservation details for this PaymentIntent. */ public Builder setFlight(PaymentIntentCreateParams.PaymentDetails.Flight flight) { this.flight = flight; @@ -8466,29 +8807,7 @@ public enum Mode implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class Flight { - /** Affiliate details for this purchase. */ - @SerializedName("affiliate") - Affiliate affiliate; - - /** - * The agency number (i.e. International Air Transport Association (IATA) agency number) of - * the travel agency that made the booking. - */ - @SerializedName("agency_number") - String agencyNumber; - - /** - * The International Air Transport Association (IATA) carrier code of the carrier that issued - * the ticket. - */ - @SerializedName("carrier") - String carrier; - - /** Delivery details for this purchase. */ - @SerializedName("delivery") - Delivery delivery; - + public static class FleetData { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -8498,41 +8817,27 @@ public static class Flight { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** The name of the person or entity on the reservation. */ - @SerializedName("passenger_name") - String passengerName; - - /** The details of the passengers in the travel reservation. */ - @SerializedName("passengers") - List passengers; + /** Primary fuel fields for the transaction. */ + @SerializedName("primary_fuel_fields") + PrimaryFuelFields primaryFuelFields; - /** Required. The individual flight segments associated with the trip. */ - @SerializedName("segments") - List segments; + /** Station and acceptor location details. */ + @SerializedName("station") + Station station; - /** The ticket number associated with the travel reservation. */ - @SerializedName("ticket_number") - String ticketNumber; + /** VAT and Invoice on Behalf (IOB) details. */ + @SerializedName("vat") + Vat vat; - private Flight( - Affiliate affiliate, - String agencyNumber, - String carrier, - Delivery delivery, + private FleetData( Map extraParams, - String passengerName, - List passengers, - List segments, - String ticketNumber) { - this.affiliate = affiliate; - this.agencyNumber = agencyNumber; - this.carrier = carrier; - this.delivery = delivery; + PrimaryFuelFields primaryFuelFields, + Station station, + Vat vat) { this.extraParams = extraParams; - this.passengerName = passengerName; - this.passengers = passengers; - this.segments = segments; - this.ticketNumber = ticketNumber; + this.primaryFuelFields = primaryFuelFields; + this.station = station; + this.vat = vat; } public static Builder builder() { @@ -8540,75 +8845,25 @@ public static Builder builder() { } public static class Builder { - private Affiliate affiliate; - - private String agencyNumber; - - private String carrier; - - private Delivery delivery; - private Map extraParams; - private String passengerName; - - private List passengers; + private PrimaryFuelFields primaryFuelFields; - private List segments; + private Station station; - private String ticketNumber; + private Vat vat; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.Flight build() { - return new PaymentIntentCreateParams.PaymentDetails.Flight( - this.affiliate, - this.agencyNumber, - this.carrier, - this.delivery, - this.extraParams, - this.passengerName, - this.passengers, - this.segments, - this.ticketNumber); - } - - /** Affiliate details for this purchase. */ - public Builder setAffiliate( - PaymentIntentCreateParams.PaymentDetails.Flight.Affiliate affiliate) { - this.affiliate = affiliate; - return this; + public PaymentIntentCreateParams.PaymentDetails.FleetData build() { + return new PaymentIntentCreateParams.PaymentDetails.FleetData( + this.extraParams, this.primaryFuelFields, this.station, this.vat); } /** - * The agency number (i.e. International Air Transport Association (IATA) agency number) of - * the travel agency that made the booking. - */ - public Builder setAgencyNumber(String agencyNumber) { - this.agencyNumber = agencyNumber; - return this; - } - - /** - * The International Air Transport Association (IATA) carrier code of the carrier that - * issued the ticket. - */ - public Builder setCarrier(String carrier) { - this.carrier = carrier; - return this; - } - - /** Delivery details for this purchase. */ - public Builder setDelivery( - PaymentIntentCreateParams.PaymentDetails.Flight.Delivery delivery) { - this.delivery = delivery; - return this; - } - - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight#extraParams} for the - * field documentation. + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.FleetData#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -8621,7 +8876,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight#extraParams} for the + * map. See {@link PaymentIntentCreateParams.PaymentDetails.FleetData#extraParams} for the * field documentation. */ public Builder putAllExtraParam(Map map) { @@ -8632,77 +8887,35 @@ public Builder putAllExtraParam(Map map) { return this; } - /** The name of the person or entity on the reservation. */ - public Builder setPassengerName(String passengerName) { - this.passengerName = passengerName; - return this; - } - - /** - * Add an element to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.Flight#passengers} for the field documentation. - */ - public Builder addPassenger( - PaymentIntentCreateParams.PaymentDetails.Flight.Passenger element) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.add(element); - return this; - } - - /** - * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.Flight#passengers} for the field documentation. - */ - public Builder addAllPassenger( - List elements) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.addAll(elements); - return this; - } - - /** - * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.Flight#segments} for the field documentation. - */ - public Builder addSegment(PaymentIntentCreateParams.PaymentDetails.Flight.Segment element) { - if (this.segments == null) { - this.segments = new ArrayList<>(); - } - this.segments.add(element); + /** Primary fuel fields for the transaction. */ + public Builder setPrimaryFuelFields( + PaymentIntentCreateParams.PaymentDetails.FleetData.PrimaryFuelFields + primaryFuelFields) { + this.primaryFuelFields = primaryFuelFields; return this; } - /** - * Add all elements to `segments` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.Flight#segments} for the field documentation. - */ - public Builder addAllSegment( - List elements) { - if (this.segments == null) { - this.segments = new ArrayList<>(); - } - this.segments.addAll(elements); + /** Station and acceptor location details. */ + public Builder setStation( + PaymentIntentCreateParams.PaymentDetails.FleetData.Station station) { + this.station = station; return this; } - /** The ticket number associated with the travel reservation. */ - public Builder setTicketNumber(String ticketNumber) { - this.ticketNumber = ticketNumber; + /** VAT and Invoice on Behalf (IOB) details. */ + public Builder setVat(PaymentIntentCreateParams.PaymentDetails.FleetData.Vat vat) { + this.vat = vat; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Affiliate { + public static class PrimaryFuelFields { + /** The fuel brand. */ + @SerializedName("brand") + Brand brand; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -8713,13 +8926,9 @@ public static class Affiliate { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Required. The name of the affiliate that originated the purchase. */ - @SerializedName("name") - String name; - - private Affiliate(Map extraParams, String name) { + private PrimaryFuelFields(Brand brand, Map extraParams) { + this.brand = brand; this.extraParams = extraParams; - this.name = name; } public static Builder builder() { @@ -8727,21 +8936,29 @@ public static Builder builder() { } public static class Builder { - private Map extraParams; + private Brand brand; - private String name; + private Map extraParams; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.Flight.Affiliate build() { - return new PaymentIntentCreateParams.PaymentDetails.Flight.Affiliate( - this.extraParams, this.name); + public PaymentIntentCreateParams.PaymentDetails.FleetData.PrimaryFuelFields build() { + return new PaymentIntentCreateParams.PaymentDetails.FleetData.PrimaryFuelFields( + this.brand, this.extraParams); + } + + /** The fuel brand. */ + public Builder setBrand( + PaymentIntentCreateParams.PaymentDetails.FleetData.PrimaryFuelFields.Brand brand) { + this.brand = brand; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight.Affiliate#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FleetData.PrimaryFuelFields#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -8754,8 +8971,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight.Affiliate#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FleetData.PrimaryFuelFields#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -8764,221 +8982,409 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } - - /** Required. The name of the affiliate that originated the purchase. */ - public Builder setName(String name) { - this.name = name; - return this; - } } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Delivery { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public enum Brand implements ApiRequestParams.EnumParam { + @SerializedName("aafes") + AAFES("aafes"), - /** The delivery method for the payment. */ - @SerializedName("mode") - Mode mode; + @SerializedName("amerada_hess") + AMERADA_HESS("amerada_hess"), - /** Details of the recipient. */ - @SerializedName("recipient") - Recipient recipient; + @SerializedName("amoco_canada") + AMOCO_CANADA("amoco_canada"), - private Delivery(Map extraParams, Mode mode, Recipient recipient) { - this.extraParams = extraParams; - this.mode = mode; - this.recipient = recipient; - } + @SerializedName("amoco_petroleum_products") + AMOCO_PETROLEUM_PRODUCTS("amoco_petroleum_products"), - public static Builder builder() { - return new Builder(); - } + @SerializedName("arco_products") + ARCO_PRODUCTS("arco_products"), - public static class Builder { - private Map extraParams; + @SerializedName("asda") + ASDA("asda"), - private Mode mode; + @SerializedName("ashland_oil") + ASHLAND_OIL("ashland_oil"), - private Recipient recipient; + @SerializedName("bfl") + BFL("bfl"), - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.Flight.Delivery build() { - return new PaymentIntentCreateParams.PaymentDetails.Flight.Delivery( - this.extraParams, this.mode, this.recipient); - } + @SerializedName("bp_mobil") + BP_MOBIL("bp_mobil"), - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight.Delivery#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + @SerializedName("bp_oil") + BP_OIL("bp_oil"), - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight.Delivery#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + @SerializedName("burrnah_major") + BURRNAH_MAJOR("burrnah_major"), - /** The delivery method for the payment. */ - public Builder setMode( - PaymentIntentCreateParams.PaymentDetails.Flight.Delivery.Mode mode) { - this.mode = mode; - return this; - } + @SerializedName("butler_arndale") + BUTLER_ARNDALE("butler_arndale"), - /** Details of the recipient. */ - public Builder setRecipient( - PaymentIntentCreateParams.PaymentDetails.Flight.Delivery.Recipient recipient) { - this.recipient = recipient; - return this; - } - } + @SerializedName("canadian_tire") + CANADIAN_TIRE("canadian_tire"), - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Recipient { - /** The email of the recipient the ticket is delivered to. */ - @SerializedName("email") - String email; + @SerializedName("canadian_turbo") + CANADIAN_TURBO("canadian_turbo"), - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + @SerializedName("caseys_general_store") + CASEYS_GENERAL_STORE("caseys_general_store"), - /** The name of the recipient the ticket is delivered to. */ - @SerializedName("name") - String name; + @SerializedName("cenex") + CENEX("cenex"), - /** The phone number of the recipient the ticket is delivered to. */ - @SerializedName("phone") - String phone; + @SerializedName("chevron_canada") + CHEVRON_CANADA("chevron_canada"), - private Recipient( - String email, Map extraParams, String name, String phone) { - this.email = email; - this.extraParams = extraParams; - this.name = name; - this.phone = phone; - } + @SerializedName("chevron_usa") + CHEVRON_USA("chevron_usa"), - public static Builder builder() { - return new Builder(); - } + @SerializedName("circle_k_stores") + CIRCLE_K_STORES("circle_k_stores"), - public static class Builder { - private String email; + @SerializedName("citgo_petroleum") + CITGO_PETROLEUM("citgo_petroleum"), - private Map extraParams; + @SerializedName("clark_brands") + CLARK_BRANDS("clark_brands"), - private String name; + @SerializedName("conoco_canada") + CONOCO_CANADA("conoco_canada"), - private String phone; + @SerializedName("conoco_inc") + CONOCO_INC("conoco_inc"), - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.Flight.Delivery.Recipient build() { - return new PaymentIntentCreateParams.PaymentDetails.Flight.Delivery.Recipient( - this.email, this.extraParams, this.name, this.phone); - } + @SerializedName("crown_central_petroleum") + CROWN_CENTRAL_PETROLEUM("crown_central_petroleum"), - /** The email of the recipient the ticket is delivered to. */ - public Builder setEmail(String email) { - this.email = email; - return this; - } + @SerializedName("diamond_shamrock_inc") + DIAMOND_SHAMROCK_INC("diamond_shamrock_inc"), - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + @SerializedName("discount_tire") + DISCOUNT_TIRE("discount_tire"), - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + @SerializedName("domo_gas") + DOMO_GAS("domo_gas"), - /** The name of the recipient the ticket is delivered to. */ - public Builder setName(String name) { - this.name = name; - return this; - } + @SerializedName("elf") + ELF("elf"), - /** The phone number of the recipient the ticket is delivered to. */ - public Builder setPhone(String phone) { - this.phone = phone; - return this; - } - } - } + @SerializedName("erickson_oil") + ERICKSON_OIL("erickson_oil"), - public enum Mode implements ApiRequestParams.EnumParam { - @SerializedName("email") - EMAIL("email"), + @SerializedName("esso") + ESSO("esso"), - @SerializedName("phone") - PHONE("phone"), + @SerializedName("esso_canada") + ESSO_CANADA("esso_canada"), - @SerializedName("pickup") - PICKUP("pickup"), + @SerializedName("exxon") + EXXON("exxon"), - @SerializedName("post") - POST("post"); + @SerializedName("exxonmobil") + EXXONMOBIL("exxonmobil"), + + @SerializedName("family_express") + FAMILY_EXPRESS("family_express"), + + @SerializedName("fas_gas_oil") + FAS_GAS_OIL("fas_gas_oil"), + + @SerializedName("federated_coop_sonic") + FEDERATED_COOP_SONIC("federated_coop_sonic"), + + @SerializedName("fina") + FINA("fina"), + + @SerializedName("fina_inc") + FINA_INC("fina_inc"), + + @SerializedName("fkg_oil") + FKG_OIL("fkg_oil"), + + @SerializedName("flare") + FLARE("flare"), + + @SerializedName("flying_j_inc") + FLYING_J_INC("flying_j_inc"), + + @SerializedName("gas_america") + GAS_AMERICA("gas_america"), + + @SerializedName("gate_petroleum") + GATE_PETROLEUM("gate_petroleum"), + + @SerializedName("getty_petroleum") + GETTY_PETROLEUM("getty_petroleum"), + + @SerializedName("giant_eagle") + GIANT_EAGLE("giant_eagle"), + + @SerializedName("grow_mark_inc") + GROW_MARK_INC("grow_mark_inc"), + + @SerializedName("gulf") + GULF("gulf"), + + @SerializedName("gulf_canada") + GULF_CANADA("gulf_canada"), + + @SerializedName("gulf_chevron") + GULF_CHEVRON("gulf_chevron"), + + @SerializedName("handy_way_food") + HANDY_WAY_FOOD("handy_way_food"), + + @SerializedName("heron") + HERON("heron"), + + @SerializedName("holiday_stores") + HOLIDAY_STORES("holiday_stores"), + + @SerializedName("home_depot") + HOME_DEPOT("home_depot"), + + @SerializedName("husky") + HUSKY("husky"), + + @SerializedName("hyvees") + HYVEES("hyvees"), + + @SerializedName("irving") + IRVING("irving"), + + @SerializedName("irving_oil") + IRVING_OIL("irving_oil"), + + @SerializedName("j_sainsbury") + J_SAINSBURY("j_sainsbury"), + + @SerializedName("jet_conoco") + JET_CONOCO("jet_conoco"), + + @SerializedName("krogers") + KROGERS("krogers"), + + @SerializedName("kuwait") + KUWAIT("kuwait"), + + @SerializedName("kwik_trip_inc") + KWIK_TRIP_INC("kwik_trip_inc"), + + @SerializedName("lassus") + LASSUS("lassus"), + + @SerializedName("loves_country_stores") + LOVES_COUNTRY_STORES("loves_country_stores"), + + @SerializedName("mapco_express_inc") + MAPCO_EXPRESS_INC("mapco_express_inc"), + + @SerializedName("marathon_oil") + MARATHON_OIL("marathon_oil"), + + @SerializedName("martin_bailey_inc_dba_hucks") + MARTIN_BAILEY_INC_DBA_HUCKS("martin_bailey_inc_dba_hucks"), + + @SerializedName("maxol") + MAXOL("maxol"), + + @SerializedName("meineke") + MEINEKE("meineke"), + + @SerializedName("mfa") + MFA("mfa"), + + @SerializedName("mohawk") + MOHAWK("mohawk"), + + @SerializedName("mr_gas") + MR_GAS("mr_gas"), + + @SerializedName("murco") + MURCO("murco"), + + @SerializedName("murphy_oil_canada") + MURPHY_OIL_CANADA("murphy_oil_canada"), + + @SerializedName("murphy_oil_usa_inc") + MURPHY_OIL_USA_INC("murphy_oil_usa_inc"), + + @SerializedName("nexcom") + NEXCOM("nexcom"), + + @SerializedName("nordstrom_oil") + NORDSTROM_OIL("nordstrom_oil"), + + @SerializedName("olco") + OLCO("olco"), + + @SerializedName("pdq_store") + PDQ_STORE("pdq_store"), + + @SerializedName("pennzoil_products_inc") + PENNZOIL_PRODUCTS_INC("pennzoil_products_inc"), + + @SerializedName("petro") + PETRO("petro"), + + @SerializedName("petro_canada") + PETRO_CANADA("petro_canada"), + + @SerializedName("petro_t") + PETRO_T("petro_t"), + + @SerializedName("phillips") + PHILLIPS("phillips"), + + @SerializedName("pilot") + PILOT("pilot"), + + @SerializedName("pioneer") + PIONEER("pioneer"), + + @SerializedName("pure_oil") + PURE_OIL("pure_oil"), + + @SerializedName("quaker_state") + QUAKER_STATE("quaker_state"), + + @SerializedName("quarles_oil") + QUARLES_OIL("quarles_oil"), + + @SerializedName("quiktrip") + QUIKTRIP("quiktrip"), + + @SerializedName("racetrac_petroleum_inc") + RACETRAC_PETROLEUM_INC("racetrac_petroleum_inc"), + + @SerializedName("raceway_petroleum") + RACEWAY_PETROLEUM("raceway_petroleum"), + + @SerializedName("repsol") + REPSOL("repsol"), + + @SerializedName("rudy") + RUDY("rudy"), + + @SerializedName("safeway") + SAFEWAY("safeway"), + + @SerializedName("seven_eleven") + SEVEN_ELEVEN("seven_eleven"), + + @SerializedName("sheetz") + SHEETZ("sheetz"), + + @SerializedName("shell") + SHELL("shell"), + + @SerializedName("shell_canada") + SHELL_CANADA("shell_canada"), + + @SerializedName("shell_oil") + SHELL_OIL("shell_oil"), + + @SerializedName("sinclair_oil") + SINCLAIR_OIL("sinclair_oil"), + + @SerializedName("southland_oil") + SOUTHLAND_OIL("southland_oil"), + + @SerializedName("spar") + SPAR("spar"), + + @SerializedName("speedway") + SPEEDWAY("speedway"), + + @SerializedName("sun_company_inc") + SUN_COMPANY_INC("sun_company_inc"), + + @SerializedName("suncor_sunoco_canada") + SUNCOR_SUNOCO_CANADA("suncor_sunoco_canada"), + + @SerializedName("tempo") + TEMPO("tempo"), + + @SerializedName("tesco") + TESCO("tesco"), + + @SerializedName("tesoro_alaska") + TESORO_ALASKA("tesoro_alaska"), + + @SerializedName("texaco") + TEXACO("texaco"), + + @SerializedName("the_pantry_inc") + THE_PANTRY_INC("the_pantry_inc"), + + @SerializedName("thornton_oil") + THORNTON_OIL("thornton_oil"), + + @SerializedName("tosco") + TOSCO("tosco"), + + @SerializedName("total") + TOTAL("total"), + + @SerializedName("travel_centers_of_america") + TRAVEL_CENTERS_OF_AMERICA("travel_centers_of_america"), + + @SerializedName("uk") + UK("uk"), + + @SerializedName("ultramar_canada") + ULTRAMAR_CANADA("ultramar_canada"), + + @SerializedName("unbranded_or_unassigned") + UNBRANDED_OR_UNASSIGNED("unbranded_or_unassigned"), + + @SerializedName("unbranded_unassigned") + UNBRANDED_UNASSIGNED("unbranded_unassigned"), + + @SerializedName("union_76") + UNION_76("union_76"), + + @SerializedName("united_dairy_farmer") + UNITED_DAIRY_FARMER("united_dairy_farmer"), + + @SerializedName("united_refining_kwikfill") + UNITED_REFINING_KWIKFILL("united_refining_kwikfill"), + + @SerializedName("us_oil") + US_OIL("us_oil"), + + @SerializedName("usa_petroleum") + USA_PETROLEUM("usa_petroleum"), + + @SerializedName("valvoline") + VALVOLINE("valvoline"), + + @SerializedName("vg") + VG("vg"), + + @SerializedName("w_morrison") + W_MORRISON("w_morrison"), + + @SerializedName("warren_equities") + WARREN_EQUITIES("warren_equities"), + + @SerializedName("wawa") + WAWA("wawa"), + + @SerializedName("western_energetix") + WESTERN_ENERGETIX("western_energetix"), + + @SerializedName("wilco") + WILCO("wilco"), + + @SerializedName("zions") + ZIONS("zions"); @Getter(onMethod_ = {@Override}) private final String value; - Mode(String value) { + Brand(String value) { this.value = value; } } @@ -8986,7 +9392,15 @@ public enum Mode implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class Passenger { + public static class Station { + /** Additional contact information for the station. */ + @SerializedName("additional_contact_info") + String additionalContactInfo; + + /** The customer service phone number of the station. */ + @SerializedName("customer_service_phone_number") + String customerServicePhoneNumber; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -8997,15 +9411,37 @@ public static class Passenger { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** - * Required. Full name of the person or entity on the flight reservation. - */ - @SerializedName("name") - String name; + /** The partner ID code of the station. */ + @SerializedName("partner_id_code") + String partnerIdCode; - private Passenger(Map extraParams, String name) { + /** The phone number of the station. */ + @SerializedName("phone_number") + String phoneNumber; + + /** The physical location of the station. */ + @SerializedName("service_location") + ServiceLocation serviceLocation; + + /** The URL of the station. */ + @SerializedName("url") + String url; + + private Station( + String additionalContactInfo, + String customerServicePhoneNumber, + Map extraParams, + String partnerIdCode, + String phoneNumber, + ServiceLocation serviceLocation, + String url) { + this.additionalContactInfo = additionalContactInfo; + this.customerServicePhoneNumber = customerServicePhoneNumber; this.extraParams = extraParams; - this.name = name; + this.partnerIdCode = partnerIdCode; + this.phoneNumber = phoneNumber; + this.serviceLocation = serviceLocation; + this.url = url; } public static Builder builder() { @@ -9013,20 +9449,48 @@ public static Builder builder() { } public static class Builder { + private String additionalContactInfo; + + private String customerServicePhoneNumber; + private Map extraParams; - private String name; + private String partnerIdCode; + + private String phoneNumber; + + private ServiceLocation serviceLocation; + + private String url; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.Flight.Passenger build() { - return new PaymentIntentCreateParams.PaymentDetails.Flight.Passenger( - this.extraParams, this.name); + public PaymentIntentCreateParams.PaymentDetails.FleetData.Station build() { + return new PaymentIntentCreateParams.PaymentDetails.FleetData.Station( + this.additionalContactInfo, + this.customerServicePhoneNumber, + this.extraParams, + this.partnerIdCode, + this.phoneNumber, + this.serviceLocation, + this.url); + } + + /** Additional contact information for the station. */ + public Builder setAdditionalContactInfo(String additionalContactInfo) { + this.additionalContactInfo = additionalContactInfo; + return this; + } + + /** The customer service phone number of the station. */ + public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight.Passenger#extraParams} + * map. See {@link PaymentIntentCreateParams.PaymentDetails.FleetData.Station#extraParams} * for the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -9040,7 +9504,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight.Passenger#extraParams} + * map. See {@link PaymentIntentCreateParams.PaymentDetails.FleetData.Station#extraParams} * for the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -9051,183 +9515,250 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Required. Full name of the person or entity on the flight reservation. - */ - public Builder setName(String name) { - this.name = name; + /** The partner ID code of the station. */ + public Builder setPartnerIdCode(String partnerIdCode) { + this.partnerIdCode = partnerIdCode; return this; } - } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Segment { - /** The flight segment amount. */ - @SerializedName("amount") - Long amount; + /** The phone number of the station. */ + public Builder setPhoneNumber(String phoneNumber) { + this.phoneNumber = phoneNumber; + return this; + } - /** - * The International Air Transport Association (IATA) airport code for the arrival airport. - */ - @SerializedName("arrival_airport") - String arrivalAirport; + /** The physical location of the station. */ + public Builder setServiceLocation( + PaymentIntentCreateParams.PaymentDetails.FleetData.Station.ServiceLocation + serviceLocation) { + this.serviceLocation = serviceLocation; + return this; + } - /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ - @SerializedName("arrives_at") - Long arrivesAt; + /** The URL of the station. */ + public Builder setUrl(String url) { + this.url = url; + return this; + } + } - /** - * The International Air Transport Association (IATA) carrier code of the carrier operating - * the flight segment. - */ - @SerializedName("carrier") - String carrier; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ServiceLocation { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + String city; - /** - * Required. The departure time for the flight segment. Measured in seconds - * since the Unix epoch. - */ - @SerializedName("departs_at") - Long departsAt; + /** + * Two-letter country code (ISO + * 3166-1 alpha-2). + */ + @SerializedName("country") + String country; - /** - * The International Air Transport Association (IATA) airport code for the departure - * airport. - */ - @SerializedName("departure_airport") - String departureAirport; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** + * Required. Address line 1, such as the street, PO Box, or company name. + */ + @SerializedName("line1") + String line1; - /** The flight number associated with the segment. */ - @SerializedName("flight_number") - String flightNumber; + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; - /** The fare class for the segment. */ - @SerializedName("service_class") - ServiceClass serviceClass; + /** ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; - private Segment( - Long amount, - String arrivalAirport, - Long arrivesAt, - String carrier, - Long departsAt, - String departureAirport, - Map extraParams, - String flightNumber, - ServiceClass serviceClass) { - this.amount = amount; - this.arrivalAirport = arrivalAirport; - this.arrivesAt = arrivesAt; - this.carrier = carrier; - this.departsAt = departsAt; - this.departureAirport = departureAirport; - this.extraParams = extraParams; - this.flightNumber = flightNumber; - this.serviceClass = serviceClass; - } + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; - public static Builder builder() { - return new Builder(); - } + private ServiceLocation( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } - public static class Builder { - private Long amount; + public static Builder builder() { + return new Builder(); + } - private String arrivalAirport; + public static class Builder { + private String city; - private Long arrivesAt; + private String country; - private String carrier; + private Map extraParams; - private Long departsAt; + private String line1; - private String departureAirport; + private String line2; - private Map extraParams; + private String postalCode; - private String flightNumber; + private String state; - private ServiceClass serviceClass; + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.FleetData.Station.ServiceLocation + build() { + return new PaymentIntentCreateParams.PaymentDetails.FleetData.Station.ServiceLocation( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.Flight.Segment build() { - return new PaymentIntentCreateParams.PaymentDetails.Flight.Segment( - this.amount, - this.arrivalAirport, - this.arrivesAt, - this.carrier, - this.departsAt, - this.departureAirport, - this.extraParams, - this.flightNumber, - this.serviceClass); - } + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } - /** The flight segment amount. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } - /** - * The International Air Transport Association (IATA) airport code for the arrival - * airport. - */ - public Builder setArrivalAirport(String arrivalAirport) { - this.arrivalAirport = arrivalAirport; - return this; - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FleetData.Station.ServiceLocation#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ - public Builder setArrivesAt(Long arrivesAt) { - this.arrivesAt = arrivesAt; - return this; - } + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FleetData.Station.ServiceLocation#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** - * The International Air Transport Association (IATA) carrier code of the carrier - * operating the flight segment. - */ - public Builder setCarrier(String carrier) { - this.carrier = carrier; - return this; - } + /** + * Required. Address line 1, such as the street, PO Box, or company + * name. + */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } - /** - * Required. The departure time for the flight segment. Measured in - * seconds since the Unix epoch. - */ - public Builder setDepartsAt(Long departsAt) { - this.departsAt = departsAt; - return this; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } + + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } + + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } } + } + } - /** - * The International Air Transport Association (IATA) airport code for the departure - * airport. - */ - public Builder setDepartureAirport(String departureAirport) { - this.departureAirport = departureAirport; - return this; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Vat { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** + * Required. Indicates the merchant's agreement for Invoice on Behalf (IOB) + * VAT processing. + */ + @SerializedName("iob_indicator") + IobIndicator iobIndicator; + + private Vat(Map extraParams, IobIndicator iobIndicator) { + this.extraParams = extraParams; + this.iobIndicator = iobIndicator; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private IobIndicator iobIndicator; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.FleetData.Vat build() { + return new PaymentIntentCreateParams.PaymentDetails.FleetData.Vat( + this.extraParams, this.iobIndicator); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight.Segment#extraParams} - * for the field documentation. + * map. See {@link PaymentIntentCreateParams.PaymentDetails.FleetData.Vat#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -9240,8 +9771,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight.Segment#extraParams} - * for the field documentation. + * map. See {@link PaymentIntentCreateParams.PaymentDetails.FleetData.Vat#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -9251,37 +9782,32 @@ public Builder putAllExtraParam(Map map) { return this; } - /** The flight number associated with the segment. */ - public Builder setFlightNumber(String flightNumber) { - this.flightNumber = flightNumber; - return this; - } - - /** The fare class for the segment. */ - public Builder setServiceClass( - PaymentIntentCreateParams.PaymentDetails.Flight.Segment.ServiceClass serviceClass) { - this.serviceClass = serviceClass; + /** + * Required. Indicates the merchant's agreement for Invoice on Behalf + * (IOB) VAT processing. + */ + public Builder setIobIndicator( + PaymentIntentCreateParams.PaymentDetails.FleetData.Vat.IobIndicator iobIndicator) { + this.iobIndicator = iobIndicator; return this; } } - public enum ServiceClass implements ApiRequestParams.EnumParam { - @SerializedName("business") - BUSINESS("business"), - - @SerializedName("economy") - ECONOMY("economy"), + public enum IobIndicator implements ApiRequestParams.EnumParam { + @SerializedName("issuer_to_iob") + ISSUER_TO_IOB("issuer_to_iob"), - @SerializedName("first") - FIRST("first"), + @SerializedName("issuer_to_iob_and_incremental_certification") + ISSUER_TO_IOB_AND_INCREMENTAL_CERTIFICATION( + "issuer_to_iob_and_incremental_certification"), - @SerializedName("premium_economy") - PREMIUM_ECONOMY("premium_economy"); + @SerializedName("merchant_does_not_agree_to_iob") + MERCHANT_DOES_NOT_AGREE_TO_IOB("merchant_does_not_agree_to_iob"); @Getter(onMethod_ = {@Override}) private final String value; - ServiceClass(String value) { + IobIndicator(String value) { this.value = value; } } @@ -9290,22 +9816,28 @@ public enum ServiceClass implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class FlightData { - /** Affiliate details if applicable. */ - @SerializedName("affiliate") + public static class Flight { + /** Affiliate details for this purchase. */ + @SerializedName("affiliate") Affiliate affiliate; - /** Reservation reference. */ - @SerializedName("booking_number") - String bookingNumber; + /** + * The agency number (i.e. International Air Transport Association (IATA) agency number) of + * the travel agency that made the booking. + */ + @SerializedName("agency_number") + String agencyNumber; - /** Computerized reservation system used to make the reservation and purchase the ticket. */ - @SerializedName("computerized_reservation_system") - String computerizedReservationSystem; + /** + * The International Air Transport Association (IATA) carrier code of the carrier that issued + * the ticket. + */ + @SerializedName("carrier") + String carrier; - /** Ticket restrictions. */ - @SerializedName("endorsements_and_restrictions") - String endorsementsAndRestrictions; + /** Delivery details for this purchase. */ + @SerializedName("delivery") + Delivery delivery; /** * Map of extra parameters for custom features not available in this client library. The @@ -9316,53 +9848,41 @@ public static class FlightData { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** List of insurances. */ - @SerializedName("insurances") - List insurances; + /** The name of the person or entity on the reservation. */ + @SerializedName("passenger_name") + String passengerName; - /** List of passengers. */ + /** The details of the passengers in the travel reservation. */ @SerializedName("passengers") - List passengers; + List passengers; - /** Required. List of flight segments. */ + /** Required. The individual flight segments associated with the trip. */ @SerializedName("segments") - List segments; - - /** Electronic ticket indicator. */ - @SerializedName("ticket_electronically_issued_indicator") - Boolean ticketElectronicallyIssuedIndicator; - - /** Required. Total cost breakdown. */ - @SerializedName("total") - Total total; + List segments; - /** Type of flight transaction. */ - @SerializedName("transaction_type") - TransactionType transactionType; + /** The ticket number associated with the travel reservation. */ + @SerializedName("ticket_number") + String ticketNumber; - private FlightData( + private Flight( Affiliate affiliate, - String bookingNumber, - String computerizedReservationSystem, - String endorsementsAndRestrictions, + String agencyNumber, + String carrier, + Delivery delivery, Map extraParams, - List insurances, - List passengers, - List segments, - Boolean ticketElectronicallyIssuedIndicator, - Total total, - TransactionType transactionType) { + String passengerName, + List passengers, + List segments, + String ticketNumber) { this.affiliate = affiliate; - this.bookingNumber = bookingNumber; - this.computerizedReservationSystem = computerizedReservationSystem; - this.endorsementsAndRestrictions = endorsementsAndRestrictions; + this.agencyNumber = agencyNumber; + this.carrier = carrier; + this.delivery = delivery; this.extraParams = extraParams; - this.insurances = insurances; + this.passengerName = passengerName; this.passengers = passengers; this.segments = segments; - this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; - this.total = total; - this.transactionType = transactionType; + this.ticketNumber = ticketNumber; } public static Builder builder() { @@ -9372,71 +9892,72 @@ public static Builder builder() { public static class Builder { private Affiliate affiliate; - private String bookingNumber; + private String agencyNumber; - private String computerizedReservationSystem; + private String carrier; - private String endorsementsAndRestrictions; + private Delivery delivery; private Map extraParams; - private List insurances; - - private List passengers; - - private List segments; + private String passengerName; - private Boolean ticketElectronicallyIssuedIndicator; + private List passengers; - private Total total; + private List segments; - private TransactionType transactionType; + private String ticketNumber; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.FlightData build() { - return new PaymentIntentCreateParams.PaymentDetails.FlightData( + public PaymentIntentCreateParams.PaymentDetails.Flight build() { + return new PaymentIntentCreateParams.PaymentDetails.Flight( this.affiliate, - this.bookingNumber, - this.computerizedReservationSystem, - this.endorsementsAndRestrictions, + this.agencyNumber, + this.carrier, + this.delivery, this.extraParams, - this.insurances, + this.passengerName, this.passengers, this.segments, - this.ticketElectronicallyIssuedIndicator, - this.total, - this.transactionType); + this.ticketNumber); } - /** Affiliate details if applicable. */ + /** Affiliate details for this purchase. */ public Builder setAffiliate( - PaymentIntentCreateParams.PaymentDetails.FlightData.Affiliate affiliate) { + PaymentIntentCreateParams.PaymentDetails.Flight.Affiliate affiliate) { this.affiliate = affiliate; return this; } - /** Reservation reference. */ - public Builder setBookingNumber(String bookingNumber) { - this.bookingNumber = bookingNumber; + /** + * The agency number (i.e. International Air Transport Association (IATA) agency number) of + * the travel agency that made the booking. + */ + public Builder setAgencyNumber(String agencyNumber) { + this.agencyNumber = agencyNumber; return this; } - /** Computerized reservation system used to make the reservation and purchase the ticket. */ - public Builder setComputerizedReservationSystem(String computerizedReservationSystem) { - this.computerizedReservationSystem = computerizedReservationSystem; + /** + * The International Air Transport Association (IATA) carrier code of the carrier that + * issued the ticket. + */ + public Builder setCarrier(String carrier) { + this.carrier = carrier; return this; } - /** Ticket restrictions. */ - public Builder setEndorsementsAndRestrictions(String endorsementsAndRestrictions) { - this.endorsementsAndRestrictions = endorsementsAndRestrictions; + /** Delivery details for this purchase. */ + public Builder setDelivery( + PaymentIntentCreateParams.PaymentDetails.Flight.Delivery delivery) { + this.delivery = delivery; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.FlightData#extraParams} for the + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight#extraParams} for the * field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -9450,7 +9971,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.FlightData#extraParams} for the + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight#extraParams} for the * field documentation. */ public Builder putAllExtraParam(Map map) { @@ -9461,44 +9982,19 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Add an element to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData#insurances} for the field - * documentation. - */ - public Builder addInsurance( - PaymentIntentCreateParams.PaymentDetails.FlightData.Insurance element) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); - } - this.insurances.add(element); - return this; - } - - /** - * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData#insurances} for the field - * documentation. - */ - public Builder addAllInsurance( - List elements) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); - } - this.insurances.addAll(elements); + /** The name of the person or entity on the reservation. */ + public Builder setPassengerName(String passengerName) { + this.passengerName = passengerName; return this; } /** * Add an element to `passengers` list. A list is initialized for the first `add/addAll` * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData#passengers} for the field - * documentation. + * PaymentIntentCreateParams.PaymentDetails.Flight#passengers} for the field documentation. */ public Builder addPassenger( - PaymentIntentCreateParams.PaymentDetails.FlightData.Passenger element) { + PaymentIntentCreateParams.PaymentDetails.Flight.Passenger element) { if (this.passengers == null) { this.passengers = new ArrayList<>(); } @@ -9509,11 +10005,10 @@ public Builder addPassenger( /** * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData#passengers} for the field - * documentation. + * PaymentIntentCreateParams.PaymentDetails.Flight#passengers} for the field documentation. */ public Builder addAllPassenger( - List elements) { + List elements) { if (this.passengers == null) { this.passengers = new ArrayList<>(); } @@ -9524,11 +10019,9 @@ public Builder addAllPassenger( /** * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, * and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData#segments} for the field - * documentation. + * PaymentIntentCreateParams.PaymentDetails.Flight#segments} for the field documentation. */ - public Builder addSegment( - PaymentIntentCreateParams.PaymentDetails.FlightData.Segment element) { + public Builder addSegment(PaymentIntentCreateParams.PaymentDetails.Flight.Segment element) { if (this.segments == null) { this.segments = new ArrayList<>(); } @@ -9539,11 +10032,10 @@ public Builder addSegment( /** * Add all elements to `segments` list. A list is initialized for the first `add/addAll` * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData#segments} for the field - * documentation. + * PaymentIntentCreateParams.PaymentDetails.Flight#segments} for the field documentation. */ public Builder addAllSegment( - List elements) { + List elements) { if (this.segments == null) { this.segments = new ArrayList<>(); } @@ -9551,23 +10043,9 @@ public Builder addAllSegment( return this; } - /** Electronic ticket indicator. */ - public Builder setTicketElectronicallyIssuedIndicator( - Boolean ticketElectronicallyIssuedIndicator) { - this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; - return this; - } - - /** Required. Total cost breakdown. */ - public Builder setTotal(PaymentIntentCreateParams.PaymentDetails.FlightData.Total total) { - this.total = total; - return this; - } - - /** Type of flight transaction. */ - public Builder setTransactionType( - PaymentIntentCreateParams.PaymentDetails.FlightData.TransactionType transactionType) { - this.transactionType = transactionType; + /** The ticket number associated with the travel reservation. */ + public Builder setTicketNumber(String ticketNumber) { + this.ticketNumber = ticketNumber; return this; } } @@ -9575,10 +10053,6 @@ public Builder setTransactionType( @Getter @EqualsAndHashCode(callSuper = false) public static class Affiliate { - /** Affiliate partner code. */ - @SerializedName("code") - String code; - /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -9589,23 +10063,13 @@ public static class Affiliate { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Name of affiliate partner. */ + /** Required. The name of the affiliate that originated the purchase. */ @SerializedName("name") String name; - /** Code provided by the company to a travel agent authorizing ticket issuance. */ - @SerializedName("travel_authorization_code") - String travelAuthorizationCode; - - private Affiliate( - String code, - Map extraParams, - String name, - String travelAuthorizationCode) { - this.code = code; + private Affiliate(Map extraParams, String name) { this.extraParams = extraParams; this.name = name; - this.travelAuthorizationCode = travelAuthorizationCode; } public static Builder builder() { @@ -9613,32 +10077,21 @@ public static Builder builder() { } public static class Builder { - private String code; - private Map extraParams; private String name; - private String travelAuthorizationCode; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.FlightData.Affiliate build() { - return new PaymentIntentCreateParams.PaymentDetails.FlightData.Affiliate( - this.code, this.extraParams, this.name, this.travelAuthorizationCode); - } - - /** Affiliate partner code. */ - public Builder setCode(String code) { - this.code = code; - return this; + public PaymentIntentCreateParams.PaymentDetails.Flight.Affiliate build() { + return new PaymentIntentCreateParams.PaymentDetails.Flight.Affiliate( + this.extraParams, this.name); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Affiliate#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight.Affiliate#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -9651,9 +10104,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Affiliate#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight.Affiliate#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -9663,31 +10115,17 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Name of affiliate partner. */ + /** Required. The name of the affiliate that originated the purchase. */ public Builder setName(String name) { this.name = name; return this; } - - /** Code provided by the company to a travel agent authorizing ticket issuance. */ - public Builder setTravelAuthorizationCode(String travelAuthorizationCode) { - this.travelAuthorizationCode = travelAuthorizationCode; - return this; - } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Insurance { - /** Required. Insurance cost. */ - @SerializedName("amount") - Long amount; - - /** Insurance currency. */ - @SerializedName("currency") - String currency; - + public static class Delivery { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -9698,25 +10136,18 @@ public static class Insurance { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Insurance company name. */ - @SerializedName("insurance_company_name") - String insuranceCompanyName; + /** The delivery method for the payment. */ + @SerializedName("mode") + Mode mode; - /** Required. Type of insurance. */ - @SerializedName("insurance_type") - InsuranceType insuranceType; + /** Details of the recipient. */ + @SerializedName("recipient") + Recipient recipient; - private Insurance( - Long amount, - String currency, - Map extraParams, - String insuranceCompanyName, - InsuranceType insuranceType) { - this.amount = amount; - this.currency = currency; + private Delivery(Map extraParams, Mode mode, Recipient recipient) { this.extraParams = extraParams; - this.insuranceCompanyName = insuranceCompanyName; - this.insuranceType = insuranceType; + this.mode = mode; + this.recipient = recipient; } public static Builder builder() { @@ -9724,44 +10155,23 @@ public static Builder builder() { } public static class Builder { - private Long amount; - - private String currency; - private Map extraParams; - private String insuranceCompanyName; + private Mode mode; - private InsuranceType insuranceType; + private Recipient recipient; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.FlightData.Insurance build() { - return new PaymentIntentCreateParams.PaymentDetails.FlightData.Insurance( - this.amount, - this.currency, - this.extraParams, - this.insuranceCompanyName, - this.insuranceType); - } - - /** Required. Insurance cost. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } - - /** Insurance currency. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; + public PaymentIntentCreateParams.PaymentDetails.Flight.Delivery build() { + return new PaymentIntentCreateParams.PaymentDetails.Flight.Delivery( + this.extraParams, this.mode, this.recipient); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Insurance#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight.Delivery#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -9774,9 +10184,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Insurance#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight.Delivery#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -9786,41 +10195,140 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Insurance company name. */ - public Builder setInsuranceCompanyName(String insuranceCompanyName) { - this.insuranceCompanyName = insuranceCompanyName; + /** The delivery method for the payment. */ + public Builder setMode( + PaymentIntentCreateParams.PaymentDetails.Flight.Delivery.Mode mode) { + this.mode = mode; return this; } - /** Required. Type of insurance. */ - public Builder setInsuranceType( - PaymentIntentCreateParams.PaymentDetails.FlightData.Insurance.InsuranceType - insuranceType) { - this.insuranceType = insuranceType; + /** Details of the recipient. */ + public Builder setRecipient( + PaymentIntentCreateParams.PaymentDetails.Flight.Delivery.Recipient recipient) { + this.recipient = recipient; return this; } } - public enum InsuranceType implements ApiRequestParams.EnumParam { - @SerializedName("baggage") - BAGGAGE("baggage"), + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Recipient { + /** The email of the recipient the ticket is delivered to. */ + @SerializedName("email") + String email; - @SerializedName("bankruptcy") - BANKRUPTCY("bankruptcy"), + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - @SerializedName("cancelation") - CANCELATION("cancelation"), + /** The name of the recipient the ticket is delivered to. */ + @SerializedName("name") + String name; - @SerializedName("emergency") - EMERGENCY("emergency"), + /** The phone number of the recipient the ticket is delivered to. */ + @SerializedName("phone") + String phone; - @SerializedName("medical") - MEDICAL("medical"); + private Recipient( + String email, Map extraParams, String name, String phone) { + this.email = email; + this.extraParams = extraParams; + this.name = name; + this.phone = phone; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String email; + + private Map extraParams; + + private String name; + + private String phone; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.Flight.Delivery.Recipient build() { + return new PaymentIntentCreateParams.PaymentDetails.Flight.Delivery.Recipient( + this.email, this.extraParams, this.name, this.phone); + } + + /** The email of the recipient the ticket is delivered to. */ + public Builder setEmail(String email) { + this.email = email; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The name of the recipient the ticket is delivered to. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** The phone number of the recipient the ticket is delivered to. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } + } + } + + public enum Mode implements ApiRequestParams.EnumParam { + @SerializedName("email") + EMAIL("email"), + + @SerializedName("phone") + PHONE("phone"), + + @SerializedName("pickup") + PICKUP("pickup"), + + @SerializedName("post") + POST("post"); @Getter(onMethod_ = {@Override}) private final String value; - InsuranceType(String value) { + Mode(String value) { this.value = value; } } @@ -9839,7 +10347,9 @@ public static class Passenger { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Required. Passenger's full name. */ + /** + * Required. Full name of the person or entity on the flight reservation. + */ @SerializedName("name") String name; @@ -9858,17 +10368,16 @@ public static class Builder { private String name; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.FlightData.Passenger build() { - return new PaymentIntentCreateParams.PaymentDetails.FlightData.Passenger( + public PaymentIntentCreateParams.PaymentDetails.Flight.Passenger build() { + return new PaymentIntentCreateParams.PaymentDetails.Flight.Passenger( this.extraParams, this.name); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Passenger#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight.Passenger#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -9881,9 +10390,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Passenger#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight.Passenger#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -9893,7 +10401,9 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Required. Passenger's full name. */ + /** + * Required. Full name of the person or entity on the flight reservation. + */ public Builder setName(String name) { this.name = name; return this; @@ -9904,33 +10414,40 @@ public Builder setName(String name) { @Getter @EqualsAndHashCode(callSuper = false) public static class Segment { - /** Segment fare amount. */ + /** The flight segment amount. */ @SerializedName("amount") Long amount; - /** Required. Arrival details. */ - @SerializedName("arrival") - Arrival arrival; - - /** Required. Airline carrier code. */ - @SerializedName("carrier_code") - String carrierCode; + /** + * The International Air Transport Association (IATA) airport code for the arrival airport. + */ + @SerializedName("arrival_airport") + String arrivalAirport; - /** Carrier name. */ - @SerializedName("carrier_name") - String carrierName; + /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ + @SerializedName("arrives_at") + Long arrivesAt; - /** Segment currency. */ - @SerializedName("currency") - String currency; + /** + * The International Air Transport Association (IATA) carrier code of the carrier operating + * the flight segment. + */ + @SerializedName("carrier") + String carrier; - /** Required. Departure details. */ - @SerializedName("departure") - Departure departure; + /** + * Required. The departure time for the flight segment. Measured in seconds + * since the Unix epoch. + */ + @SerializedName("departs_at") + Long departsAt; - /** Exchange ticket number. */ - @SerializedName("exchange_ticket_number") - String exchangeTicketNumber; + /** + * The International Air Transport Association (IATA) airport code for the departure + * airport. + */ + @SerializedName("departure_airport") + String departureAirport; /** * Map of extra parameters for custom features not available in this client library. The @@ -9942,71 +10459,33 @@ public static class Segment { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Fare basis code. */ - @SerializedName("fare_basis_code") - String fareBasisCode; - - /** Additional fees. */ - @SerializedName("fees") - Long fees; - - /** Flight number. */ + /** The flight number associated with the segment. */ @SerializedName("flight_number") String flightNumber; - /** Stopover indicator. */ - @SerializedName("is_stop_over_indicator") - Boolean isStopOverIndicator; - - /** Refundable ticket indicator. */ - @SerializedName("refundable") - Boolean refundable; - - /** Required. Class of service. */ + /** The fare class for the segment. */ @SerializedName("service_class") ServiceClass serviceClass; - /** Tax amount for segment. */ - @SerializedName("tax_amount") - Long taxAmount; - - /** Ticket number. */ - @SerializedName("ticket_number") - String ticketNumber; - private Segment( Long amount, - Arrival arrival, - String carrierCode, - String carrierName, - String currency, - Departure departure, - String exchangeTicketNumber, + String arrivalAirport, + Long arrivesAt, + String carrier, + Long departsAt, + String departureAirport, Map extraParams, - String fareBasisCode, - Long fees, String flightNumber, - Boolean isStopOverIndicator, - Boolean refundable, - ServiceClass serviceClass, - Long taxAmount, - String ticketNumber) { + ServiceClass serviceClass) { this.amount = amount; - this.arrival = arrival; - this.carrierCode = carrierCode; - this.carrierName = carrierName; - this.currency = currency; - this.departure = departure; - this.exchangeTicketNumber = exchangeTicketNumber; + this.arrivalAirport = arrivalAirport; + this.arrivesAt = arrivesAt; + this.carrier = carrier; + this.departsAt = departsAt; + this.departureAirport = departureAirport; this.extraParams = extraParams; - this.fareBasisCode = fareBasisCode; - this.fees = fees; this.flightNumber = flightNumber; - this.isStopOverIndicator = isStopOverIndicator; - this.refundable = refundable; this.serviceClass = serviceClass; - this.taxAmount = taxAmount; - this.ticketNumber = ticketNumber; } public static Builder builder() { @@ -10016,107 +10495,89 @@ public static Builder builder() { public static class Builder { private Long amount; - private Arrival arrival; - - private String carrierCode; + private String arrivalAirport; - private String carrierName; + private Long arrivesAt; - private String currency; + private String carrier; - private Departure departure; + private Long departsAt; - private String exchangeTicketNumber; + private String departureAirport; private Map extraParams; - private String fareBasisCode; - - private Long fees; - private String flightNumber; - private Boolean isStopOverIndicator; - - private Boolean refundable; - private ServiceClass serviceClass; - private Long taxAmount; - - private String ticketNumber; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.FlightData.Segment build() { - return new PaymentIntentCreateParams.PaymentDetails.FlightData.Segment( + public PaymentIntentCreateParams.PaymentDetails.Flight.Segment build() { + return new PaymentIntentCreateParams.PaymentDetails.Flight.Segment( this.amount, - this.arrival, - this.carrierCode, - this.carrierName, - this.currency, - this.departure, - this.exchangeTicketNumber, + this.arrivalAirport, + this.arrivesAt, + this.carrier, + this.departsAt, + this.departureAirport, this.extraParams, - this.fareBasisCode, - this.fees, this.flightNumber, - this.isStopOverIndicator, - this.refundable, - this.serviceClass, - this.taxAmount, - this.ticketNumber); + this.serviceClass); } - /** Segment fare amount. */ + /** The flight segment amount. */ public Builder setAmount(Long amount) { this.amount = amount; return this; } - /** Required. Arrival details. */ - public Builder setArrival( - PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Arrival arrival) { - this.arrival = arrival; - return this; - } - - /** Required. Airline carrier code. */ - public Builder setCarrierCode(String carrierCode) { - this.carrierCode = carrierCode; + /** + * The International Air Transport Association (IATA) airport code for the arrival + * airport. + */ + public Builder setArrivalAirport(String arrivalAirport) { + this.arrivalAirport = arrivalAirport; return this; } - /** Carrier name. */ - public Builder setCarrierName(String carrierName) { - this.carrierName = carrierName; + /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ + public Builder setArrivesAt(Long arrivesAt) { + this.arrivesAt = arrivesAt; return this; } - /** Segment currency. */ - public Builder setCurrency(String currency) { - this.currency = currency; + /** + * The International Air Transport Association (IATA) carrier code of the carrier + * operating the flight segment. + */ + public Builder setCarrier(String carrier) { + this.carrier = carrier; return this; } - /** Required. Departure details. */ - public Builder setDeparture( - PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Departure departure) { - this.departure = departure; + /** + * Required. The departure time for the flight segment. Measured in + * seconds since the Unix epoch. + */ + public Builder setDepartsAt(Long departsAt) { + this.departsAt = departsAt; return this; } - /** Exchange ticket number. */ - public Builder setExchangeTicketNumber(String exchangeTicketNumber) { - this.exchangeTicketNumber = exchangeTicketNumber; + /** + * The International Air Transport Association (IATA) airport code for the departure + * airport. + */ + public Builder setDepartureAirport(String departureAirport) { + this.departureAirport = departureAirport; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Segment#extraParams} for the field - * documentation. + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight.Segment#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -10129,9 +10590,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Segment#extraParams} for the field - * documentation. + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Flight.Segment#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -10141,339 +10601,333 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Fare basis code. */ - public Builder setFareBasisCode(String fareBasisCode) { - this.fareBasisCode = fareBasisCode; - return this; - } - - /** Additional fees. */ - public Builder setFees(Long fees) { - this.fees = fees; - return this; - } - - /** Flight number. */ + /** The flight number associated with the segment. */ public Builder setFlightNumber(String flightNumber) { this.flightNumber = flightNumber; return this; } - /** Stopover indicator. */ - public Builder setIsStopOverIndicator(Boolean isStopOverIndicator) { - this.isStopOverIndicator = isStopOverIndicator; - return this; - } - - /** Refundable ticket indicator. */ - public Builder setRefundable(Boolean refundable) { - this.refundable = refundable; - return this; - } - - /** Required. Class of service. */ + /** The fare class for the segment. */ public Builder setServiceClass( - PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.ServiceClass - serviceClass) { + PaymentIntentCreateParams.PaymentDetails.Flight.Segment.ServiceClass serviceClass) { this.serviceClass = serviceClass; return this; } + } - /** Tax amount for segment. */ - public Builder setTaxAmount(Long taxAmount) { - this.taxAmount = taxAmount; - return this; - } - - /** Ticket number. */ - public Builder setTicketNumber(String ticketNumber) { - this.ticketNumber = ticketNumber; - return this; - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Arrival { - /** Required. Arrival airport IATA code. */ - @SerializedName("airport") - String airport; - - /** Arrival date/time. */ - @SerializedName("arrives_at") - Long arrivesAt; + public enum ServiceClass implements ApiRequestParams.EnumParam { + @SerializedName("business") + BUSINESS("business"), - /** Arrival city. */ - @SerializedName("city") - String city; + @SerializedName("economy") + ECONOMY("economy"), - /** Arrival country. */ - @SerializedName("country") - String country; + @SerializedName("first") + FIRST("first"), - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + @SerializedName("premium_economy") + PREMIUM_ECONOMY("premium_economy"); - private Arrival( - String airport, - Long arrivesAt, - String city, - String country, - Map extraParams) { - this.airport = airport; - this.arrivesAt = arrivesAt; - this.city = city; - this.country = country; - this.extraParams = extraParams; - } + @Getter(onMethod_ = {@Override}) + private final String value; - public static Builder builder() { - return new Builder(); + ServiceClass(String value) { + this.value = value; } + } + } + } - public static class Builder { - private String airport; - - private Long arrivesAt; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class FlightData { + /** Affiliate details if applicable. */ + @SerializedName("affiliate") + Affiliate affiliate; - private String city; + /** Reservation reference. */ + @SerializedName("booking_number") + String bookingNumber; - private String country; + /** Computerized reservation system used to make the reservation and purchase the ticket. */ + @SerializedName("computerized_reservation_system") + String computerizedReservationSystem; - private Map extraParams; + /** Ticket restrictions. */ + @SerializedName("endorsements_and_restrictions") + String endorsementsAndRestrictions; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Arrival build() { - return new PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Arrival( - this.airport, this.arrivesAt, this.city, this.country, this.extraParams); - } + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Required. Arrival airport IATA code. */ - public Builder setAirport(String airport) { - this.airport = airport; - return this; - } + /** List of insurances. */ + @SerializedName("insurances") + List insurances; - /** Arrival date/time. */ - public Builder setArrivesAt(Long arrivesAt) { - this.arrivesAt = arrivesAt; - return this; - } + /** List of passengers. */ + @SerializedName("passengers") + List passengers; - /** Arrival city. */ - public Builder setCity(String city) { - this.city = city; - return this; - } + /** Required. List of flight segments. */ + @SerializedName("segments") + List segments; - /** Arrival country. */ - public Builder setCountry(String country) { - this.country = country; - return this; - } + /** Electronic ticket indicator. */ + @SerializedName("ticket_electronically_issued_indicator") + Boolean ticketElectronicallyIssuedIndicator; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Arrival#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Required. Total cost breakdown. */ + @SerializedName("total") + Total total; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Arrival#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } - } - } + /** Type of flight transaction. */ + @SerializedName("transaction_type") + TransactionType transactionType; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Departure { - /** Required. Departure airport IATA code. */ - @SerializedName("airport") - String airport; + private FlightData( + Affiliate affiliate, + String bookingNumber, + String computerizedReservationSystem, + String endorsementsAndRestrictions, + Map extraParams, + List insurances, + List passengers, + List segments, + Boolean ticketElectronicallyIssuedIndicator, + Total total, + TransactionType transactionType) { + this.affiliate = affiliate; + this.bookingNumber = bookingNumber; + this.computerizedReservationSystem = computerizedReservationSystem; + this.endorsementsAndRestrictions = endorsementsAndRestrictions; + this.extraParams = extraParams; + this.insurances = insurances; + this.passengers = passengers; + this.segments = segments; + this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; + this.total = total; + this.transactionType = transactionType; + } - /** Departure city. */ - @SerializedName("city") - String city; + public static Builder builder() { + return new Builder(); + } - /** Departure country. */ - @SerializedName("country") - String country; + public static class Builder { + private Affiliate affiliate; - /** Required. Departure date/time. */ - @SerializedName("departs_at") - Long departsAt; + private String bookingNumber; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private String computerizedReservationSystem; - private Departure( - String airport, - String city, - String country, - Long departsAt, - Map extraParams) { - this.airport = airport; - this.city = city; - this.country = country; - this.departsAt = departsAt; - this.extraParams = extraParams; - } + private String endorsementsAndRestrictions; - public static Builder builder() { - return new Builder(); - } + private Map extraParams; - public static class Builder { - private String airport; + private List insurances; - private String city; + private List passengers; - private String country; + private List segments; - private Long departsAt; + private Boolean ticketElectronicallyIssuedIndicator; - private Map extraParams; + private Total total; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Departure build() { - return new PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Departure( - this.airport, this.city, this.country, this.departsAt, this.extraParams); - } + private TransactionType transactionType; - /** Required. Departure airport IATA code. */ - public Builder setAirport(String airport) { - this.airport = airport; - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.FlightData build() { + return new PaymentIntentCreateParams.PaymentDetails.FlightData( + this.affiliate, + this.bookingNumber, + this.computerizedReservationSystem, + this.endorsementsAndRestrictions, + this.extraParams, + this.insurances, + this.passengers, + this.segments, + this.ticketElectronicallyIssuedIndicator, + this.total, + this.transactionType); + } - /** Departure city. */ - public Builder setCity(String city) { - this.city = city; - return this; - } + /** Affiliate details if applicable. */ + public Builder setAffiliate( + PaymentIntentCreateParams.PaymentDetails.FlightData.Affiliate affiliate) { + this.affiliate = affiliate; + return this; + } - /** Departure country. */ - public Builder setCountry(String country) { - this.country = country; - return this; - } + /** Reservation reference. */ + public Builder setBookingNumber(String bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } - /** Required. Departure date/time. */ - public Builder setDepartsAt(Long departsAt) { - this.departsAt = departsAt; - return this; - } + /** Computerized reservation system used to make the reservation and purchase the ticket. */ + public Builder setComputerizedReservationSystem(String computerizedReservationSystem) { + this.computerizedReservationSystem = computerizedReservationSystem; + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Departure#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Ticket restrictions. */ + public Builder setEndorsementsAndRestrictions(String endorsementsAndRestrictions) { + this.endorsementsAndRestrictions = endorsementsAndRestrictions; + return this; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Departure#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.FlightData#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.put(key, value); + return this; } - public enum ServiceClass implements ApiRequestParams.EnumParam { - @SerializedName("business") - BUSINESS("business"), + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.FlightData#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - @SerializedName("economy") - ECONOMY("economy"), + /** + * Add an element to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData#insurances} for the field + * documentation. + */ + public Builder addInsurance( + PaymentIntentCreateParams.PaymentDetails.FlightData.Insurance element) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); + } + this.insurances.add(element); + return this; + } - @SerializedName("first_class") - FIRST_CLASS("first_class"), + /** + * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData#insurances} for the field + * documentation. + */ + public Builder addAllInsurance( + List elements) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); + } + this.insurances.addAll(elements); + return this; + } - @SerializedName("premium_economy") - PREMIUM_ECONOMY("premium_economy"); + /** + * Add an element to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData#passengers} for the field + * documentation. + */ + public Builder addPassenger( + PaymentIntentCreateParams.PaymentDetails.FlightData.Passenger element) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.add(element); + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** + * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData#passengers} for the field + * documentation. + */ + public Builder addAllPassenger( + List elements) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.addAll(elements); + return this; + } - ServiceClass(String value) { - this.value = value; + /** + * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData#segments} for the field + * documentation. + */ + public Builder addSegment( + PaymentIntentCreateParams.PaymentDetails.FlightData.Segment element) { + if (this.segments == null) { + this.segments = new ArrayList<>(); } + this.segments.add(element); + return this; } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Total { - /** Required. Total flight amount. */ - @SerializedName("amount") - Long amount; + /** + * Add all elements to `segments` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData#segments} for the field + * documentation. + */ + public Builder addAllSegment( + List elements) { + if (this.segments == null) { + this.segments = new ArrayList<>(); + } + this.segments.addAll(elements); + return this; + } - /** Reason for credit. */ - @SerializedName("credit_reason") - CreditReason creditReason; + /** Electronic ticket indicator. */ + public Builder setTicketElectronicallyIssuedIndicator( + Boolean ticketElectronicallyIssuedIndicator) { + this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; + return this; + } - /** Total currency. */ - @SerializedName("currency") - String currency; + /** Required. Total cost breakdown. */ + public Builder setTotal(PaymentIntentCreateParams.PaymentDetails.FlightData.Total total) { + this.total = total; + return this; + } - /** Discount details. */ - @SerializedName("discounts") - Discounts discounts; + /** Type of flight transaction. */ + public Builder setTransactionType( + PaymentIntentCreateParams.PaymentDetails.FlightData.TransactionType transactionType) { + this.transactionType = transactionType; + return this; + } + } - /** Additional charges. */ - @SerializedName("extra_charges") - List extraCharges; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Affiliate { + /** Affiliate partner code. */ + @SerializedName("code") + String code; /** * Map of extra parameters for custom features not available in this client library. The @@ -10485,26 +10939,23 @@ public static class Total { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Tax breakdown. */ - @SerializedName("tax") - Tax tax; + /** Name of affiliate partner. */ + @SerializedName("name") + String name; - private Total( - Long amount, - CreditReason creditReason, - String currency, - Discounts discounts, - List - extraCharges, + /** Code provided by the company to a travel agent authorizing ticket issuance. */ + @SerializedName("travel_authorization_code") + String travelAuthorizationCode; + + private Affiliate( + String code, Map extraParams, - Tax tax) { - this.amount = amount; - this.creditReason = creditReason; - this.currency = currency; - this.discounts = discounts; - this.extraCharges = extraCharges; + String name, + String travelAuthorizationCode) { + this.code = code; this.extraParams = extraParams; - this.tax = tax; + this.name = name; + this.travelAuthorizationCode = travelAuthorizationCode; } public static Builder builder() { @@ -10512,95 +10963,155 @@ public static Builder builder() { } public static class Builder { - private Long amount; - - private CreditReason creditReason; - - private String currency; - - private Discounts discounts; - - private List - extraCharges; + private String code; private Map extraParams; - private Tax tax; + private String name; + + private String travelAuthorizationCode; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.FlightData.Total build() { - return new PaymentIntentCreateParams.PaymentDetails.FlightData.Total( - this.amount, - this.creditReason, - this.currency, - this.discounts, - this.extraCharges, - this.extraParams, - this.tax); + public PaymentIntentCreateParams.PaymentDetails.FlightData.Affiliate build() { + return new PaymentIntentCreateParams.PaymentDetails.FlightData.Affiliate( + this.code, this.extraParams, this.name, this.travelAuthorizationCode); } - /** Required. Total flight amount. */ - public Builder setAmount(Long amount) { - this.amount = amount; + /** Affiliate partner code. */ + public Builder setCode(String code) { + this.code = code; return this; } - /** Reason for credit. */ - public Builder setCreditReason( - PaymentIntentCreateParams.PaymentDetails.FlightData.Total.CreditReason creditReason) { - this.creditReason = creditReason; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); return this; } - /** Total currency. */ - public Builder setCurrency(String currency) { - this.currency = currency; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); return this; } - /** Discount details. */ - public Builder setDiscounts( - PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Discounts discounts) { - this.discounts = discounts; + /** Name of affiliate partner. */ + public Builder setName(String name) { + this.name = name; return this; } - /** - * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Total#extraCharges} for the field - * documentation. - */ - public Builder addExtraCharge( - PaymentIntentCreateParams.PaymentDetails.FlightData.Total.ExtraCharge element) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.add(element); + /** Code provided by the company to a travel agent authorizing ticket issuance. */ + public Builder setTravelAuthorizationCode(String travelAuthorizationCode) { + this.travelAuthorizationCode = travelAuthorizationCode; return this; } + } + } - /** - * Add all elements to `extraCharges` list. A list is initialized for the first - * `add/addAll` call, and subsequent calls adds additional elements to the original list. - * See {@link PaymentIntentCreateParams.PaymentDetails.FlightData.Total#extraCharges} for - * the field documentation. - */ - public Builder addAllExtraCharge( - List - elements) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.addAll(elements); + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Insurance { + /** Required. Insurance cost. */ + @SerializedName("amount") + Long amount; + + /** Insurance currency. */ + @SerializedName("currency") + String currency; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Insurance company name. */ + @SerializedName("insurance_company_name") + String insuranceCompanyName; + + /** Required. Type of insurance. */ + @SerializedName("insurance_type") + InsuranceType insuranceType; + + private Insurance( + Long amount, + String currency, + Map extraParams, + String insuranceCompanyName, + InsuranceType insuranceType) { + this.amount = amount; + this.currency = currency; + this.extraParams = extraParams; + this.insuranceCompanyName = insuranceCompanyName; + this.insuranceType = insuranceType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private String currency; + + private Map extraParams; + + private String insuranceCompanyName; + + private InsuranceType insuranceType; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.FlightData.Insurance build() { + return new PaymentIntentCreateParams.PaymentDetails.FlightData.Insurance( + this.amount, + this.currency, + this.extraParams, + this.insuranceCompanyName, + this.insuranceType); + } + + /** Required. Insurance cost. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Insurance currency. */ + public Builder setCurrency(String currency) { + this.currency = currency; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.FlightData.Total#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Insurance#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -10613,8 +11124,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.FlightData.Total#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Insurance#extraParams} for the + * field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -10624,902 +11136,2176 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Tax breakdown. */ - public Builder setTax(PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax tax) { - this.tax = tax; + /** Insurance company name. */ + public Builder setInsuranceCompanyName(String insuranceCompanyName) { + this.insuranceCompanyName = insuranceCompanyName; + return this; + } + + /** Required. Type of insurance. */ + public Builder setInsuranceType( + PaymentIntentCreateParams.PaymentDetails.FlightData.Insurance.InsuranceType + insuranceType) { + this.insuranceType = insuranceType; return this; } } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Discounts { - /** Corporate client discount code. */ - @SerializedName("corporate_client_code") - String corporateClientCode; + public enum InsuranceType implements ApiRequestParams.EnumParam { + @SerializedName("baggage") + BAGGAGE("baggage"), - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + @SerializedName("bankruptcy") + BANKRUPTCY("bankruptcy"), - private Discounts(String corporateClientCode, Map extraParams) { - this.corporateClientCode = corporateClientCode; - this.extraParams = extraParams; - } + @SerializedName("cancelation") + CANCELATION("cancelation"), - public static Builder builder() { - return new Builder(); - } + @SerializedName("emergency") + EMERGENCY("emergency"), - public static class Builder { - private String corporateClientCode; + @SerializedName("medical") + MEDICAL("medical"); - private Map extraParams; + @Getter(onMethod_ = {@Override}) + private final String value; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Discounts build() { - return new PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Discounts( - this.corporateClientCode, this.extraParams); - } + InsuranceType(String value) { + this.value = value; + } + } + } - /** Corporate client discount code. */ - public Builder setCorporateClientCode(String corporateClientCode) { - this.corporateClientCode = corporateClientCode; - return this; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Passenger { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Discounts#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Required. Passenger's full name. */ + @SerializedName("name") + String name; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Discounts#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } - } + private Passenger(Map extraParams, String name) { + this.extraParams = extraParams; + this.name = name; } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class ExtraCharge { - /** Amount of additional charges. */ - @SerializedName("amount") - Long amount; + public static Builder builder() { + return new Builder(); + } - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public static class Builder { + private Map extraParams; - /** Type of additional charges. */ - @SerializedName("type") - Type type; + private String name; - private ExtraCharge(Long amount, Map extraParams, Type type) { - this.amount = amount; - this.extraParams = extraParams; - this.type = type; + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.FlightData.Passenger build() { + return new PaymentIntentCreateParams.PaymentDetails.FlightData.Passenger( + this.extraParams, this.name); } - public static Builder builder() { - return new Builder(); + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Passenger#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; } - public static class Builder { - private Long amount; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Passenger#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - private Map extraParams; + /** Required. Passenger's full name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + } + } - private Type type; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Segment { + /** Segment fare amount. */ + @SerializedName("amount") + Long amount; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.FlightData.Total.ExtraCharge build() { - return new PaymentIntentCreateParams.PaymentDetails.FlightData.Total.ExtraCharge( - this.amount, this.extraParams, this.type); - } + /** Required. Arrival details. */ + @SerializedName("arrival") + Arrival arrival; - /** Amount of additional charges. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + /** Required. Airline carrier code. */ + @SerializedName("carrier_code") + String carrierCode; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.ExtraCharge#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Carrier name. */ + @SerializedName("carrier_name") + String carrierName; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.ExtraCharge#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** Segment currency. */ + @SerializedName("currency") + String currency; - /** Type of additional charges. */ - public Builder setType( - PaymentIntentCreateParams.PaymentDetails.FlightData.Total.ExtraCharge.Type type) { - this.type = type; - return this; - } - } + /** Required. Departure details. */ + @SerializedName("departure") + Departure departure; - public enum Type implements ApiRequestParams.EnumParam { - @SerializedName("additional_fees") - ADDITIONAL_FEES("additional_fees"), + /** Exchange ticket number. */ + @SerializedName("exchange_ticket_number") + String exchangeTicketNumber; - @SerializedName("ancillary_service_charges") - ANCILLARY_SERVICE_CHARGES("ancillary_service_charges"), + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - @SerializedName("exchange_fee") - EXCHANGE_FEE("exchange_fee"); + /** Fare basis code. */ + @SerializedName("fare_basis_code") + String fareBasisCode; - @Getter(onMethod_ = {@Override}) - private final String value; + /** Additional fees. */ + @SerializedName("fees") + Long fees; - Type(String value) { - this.value = value; - } - } - } + /** Flight number. */ + @SerializedName("flight_number") + String flightNumber; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Tax { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** Stopover indicator. */ + @SerializedName("is_stop_over_indicator") + Boolean isStopOverIndicator; - /** Array of tax details. */ - @SerializedName("taxes") - List taxes; - - private Tax( - Map extraParams, - List taxes) { - this.extraParams = extraParams; - this.taxes = taxes; - } - - public static Builder builder() { - return new Builder(); - } + /** Refundable ticket indicator. */ + @SerializedName("refundable") + Boolean refundable; - public static class Builder { - private Map extraParams; + /** Required. Class of service. */ + @SerializedName("service_class") + ServiceClass serviceClass; - private List - taxes; + /** Tax amount for segment. */ + @SerializedName("tax_amount") + Long taxAmount; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax build() { - return new PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax( - this.extraParams, this.taxes); - } + /** Ticket number. */ + @SerializedName("ticket_number") + String ticketNumber; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + private Segment( + Long amount, + Arrival arrival, + String carrierCode, + String carrierName, + String currency, + Departure departure, + String exchangeTicketNumber, + Map extraParams, + String fareBasisCode, + Long fees, + String flightNumber, + Boolean isStopOverIndicator, + Boolean refundable, + ServiceClass serviceClass, + Long taxAmount, + String ticketNumber) { + this.amount = amount; + this.arrival = arrival; + this.carrierCode = carrierCode; + this.carrierName = carrierName; + this.currency = currency; + this.departure = departure; + this.exchangeTicketNumber = exchangeTicketNumber; + this.extraParams = extraParams; + this.fareBasisCode = fareBasisCode; + this.fees = fees; + this.flightNumber = flightNumber; + this.isStopOverIndicator = isStopOverIndicator; + this.refundable = refundable; + this.serviceClass = serviceClass; + this.taxAmount = taxAmount; + this.ticketNumber = ticketNumber; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + public static Builder builder() { + return new Builder(); + } - /** - * Add an element to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addTax( - PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax.InnerTax element) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.add(element); - return this; - } + public static class Builder { + private Long amount; - /** - * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addAllTax( - List - elements) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.addAll(elements); - return this; - } - } + private Arrival arrival; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class InnerTax { - /** Tax amount. */ - @SerializedName("amount") - Long amount; + private String carrierCode; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} - * value. Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private String carrierName; - /** Tax rate. */ - @SerializedName("rate") - Long rate; + private String currency; - /** Type of tax. */ - @SerializedName("type") - String type; + private Departure departure; - private InnerTax(Long amount, Map extraParams, Long rate, String type) { - this.amount = amount; - this.extraParams = extraParams; - this.rate = rate; - this.type = type; - } + private String exchangeTicketNumber; - public static Builder builder() { - return new Builder(); - } + private Map extraParams; - public static class Builder { - private Long amount; + private String fareBasisCode; - private Map extraParams; + private Long fees; - private Long rate; + private String flightNumber; - private String type; + private Boolean isStopOverIndicator; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax.InnerTax - build() { - return new PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax.InnerTax( - this.amount, this.extraParams, this.rate, this.type); - } + private Boolean refundable; - /** Tax amount. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + private ServiceClass serviceClass; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax.InnerTax#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + private Long taxAmount; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the - * first `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax.InnerTax#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + private String ticketNumber; - /** Tax rate. */ - public Builder setRate(Long rate) { - this.rate = rate; - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.FlightData.Segment build() { + return new PaymentIntentCreateParams.PaymentDetails.FlightData.Segment( + this.amount, + this.arrival, + this.carrierCode, + this.carrierName, + this.currency, + this.departure, + this.exchangeTicketNumber, + this.extraParams, + this.fareBasisCode, + this.fees, + this.flightNumber, + this.isStopOverIndicator, + this.refundable, + this.serviceClass, + this.taxAmount, + this.ticketNumber); + } - /** Type of tax. */ - public Builder setType(String type) { - this.type = type; - return this; - } - } + /** Segment fare amount. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; } - } - public enum CreditReason implements ApiRequestParams.EnumParam { - @SerializedName("other") - OTHER("other"), + /** Required. Arrival details. */ + public Builder setArrival( + PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Arrival arrival) { + this.arrival = arrival; + return this; + } - @SerializedName("partial_ticket_refund") - PARTIAL_TICKET_REFUND("partial_ticket_refund"), + /** Required. Airline carrier code. */ + public Builder setCarrierCode(String carrierCode) { + this.carrierCode = carrierCode; + return this; + } - @SerializedName("passenger_transport_ancillary_cancellation") - PASSENGER_TRANSPORT_ANCILLARY_CANCELLATION("passenger_transport_ancillary_cancellation"), + /** Carrier name. */ + public Builder setCarrierName(String carrierName) { + this.carrierName = carrierName; + return this; + } - @SerializedName("ticket_and_ancillary_cancellation") - TICKET_AND_ANCILLARY_CANCELLATION("ticket_and_ancillary_cancellation"), + /** Segment currency. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; + } - @SerializedName("ticket_cancellation") - TICKET_CANCELLATION("ticket_cancellation"); + /** Required. Departure details. */ + public Builder setDeparture( + PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Departure departure) { + this.departure = departure; + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** Exchange ticket number. */ + public Builder setExchangeTicketNumber(String exchangeTicketNumber) { + this.exchangeTicketNumber = exchangeTicketNumber; + return this; + } - CreditReason(String value) { - this.value = value; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Segment#extraParams} for the field + * documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; } - } - } - public enum TransactionType implements ApiRequestParams.EnumParam { - @SerializedName("exchange_ticket") - EXCHANGE_TICKET("exchange_ticket"), + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Segment#extraParams} for the field + * documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - @SerializedName("miscellaneous") - MISCELLANEOUS("miscellaneous"), + /** Fare basis code. */ + public Builder setFareBasisCode(String fareBasisCode) { + this.fareBasisCode = fareBasisCode; + return this; + } - @SerializedName("refund") - REFUND("refund"), + /** Additional fees. */ + public Builder setFees(Long fees) { + this.fees = fees; + return this; + } - @SerializedName("ticket_purchase") - TICKET_PURCHASE("ticket_purchase"); + /** Flight number. */ + public Builder setFlightNumber(String flightNumber) { + this.flightNumber = flightNumber; + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** Stopover indicator. */ + public Builder setIsStopOverIndicator(Boolean isStopOverIndicator) { + this.isStopOverIndicator = isStopOverIndicator; + return this; + } - TransactionType(String value) { - this.value = value; - } - } - } + /** Refundable ticket indicator. */ + public Builder setRefundable(Boolean refundable) { + this.refundable = refundable; + return this; + } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Lodging { - /** The lodging location's address. */ - @SerializedName("address") - Address address; + /** Required. Class of service. */ + public Builder setServiceClass( + PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.ServiceClass + serviceClass) { + this.serviceClass = serviceClass; + return this; + } - /** The number of adults on the booking. */ - @SerializedName("adults") - Long adults; + /** Tax amount for segment. */ + public Builder setTaxAmount(Long taxAmount) { + this.taxAmount = taxAmount; + return this; + } - /** Affiliate details for this purchase. */ - @SerializedName("affiliate") - Affiliate affiliate; + /** Ticket number. */ + public Builder setTicketNumber(String ticketNumber) { + this.ticketNumber = ticketNumber; + return this; + } + } - /** The booking number associated with the lodging reservation. */ - @SerializedName("booking_number") - String bookingNumber; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Arrival { + /** Required. Arrival airport IATA code. */ + @SerializedName("airport") + String airport; - /** The lodging category. */ - @SerializedName("category") - Category category; + /** Arrival date/time. */ + @SerializedName("arrives_at") + Long arrivesAt; - /** - * Required. Lodging check-in time. Measured in seconds since the Unix epoch. - */ - @SerializedName("checkin_at") - Long checkinAt; + /** Arrival city. */ + @SerializedName("city") + String city; - /** - * Required. Lodging check-out time. Measured in seconds since the Unix - * epoch. - */ - @SerializedName("checkout_at") - Long checkoutAt; + /** Arrival country. */ + @SerializedName("country") + String country; - /** The customer service phone number of the lodging company. */ - @SerializedName("customer_service_phone_number") - String customerServicePhoneNumber; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** The daily lodging room rate. */ - @SerializedName("daily_room_rate_amount") - Long dailyRoomRateAmount; + private Arrival( + String airport, + Long arrivesAt, + String city, + String country, + Map extraParams) { + this.airport = airport; + this.arrivesAt = arrivesAt; + this.city = city; + this.country = country; + this.extraParams = extraParams; + } - /** Delivery details for this purchase. */ - @SerializedName("delivery") - Delivery delivery; + public static Builder builder() { + return new Builder(); + } - /** List of additional charges being billed. */ - @SerializedName("extra_charges") - List extraCharges; + public static class Builder { + private String airport; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) - * name in this param object. Effectively, this map is flattened to its parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private Long arrivesAt; - /** Indicates whether the lodging location is compliant with the Fire Safety Act. */ - @SerializedName("fire_safety_act_compliance") - Boolean fireSafetyActCompliance; + private String city; - /** The name of the lodging location. */ - @SerializedName("name") - String name; + private String country; - /** - * Indicates if the customer did not keep their booking while failing to cancel the - * reservation. - */ - @SerializedName("no_show") - Boolean noShow; + private Map extraParams; - /** The number of rooms on the booking. */ - @SerializedName("number_of_rooms") - Long numberOfRooms; + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Arrival build() { + return new PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Arrival( + this.airport, this.arrivesAt, this.city, this.country, this.extraParams); + } - /** The details of the passengers in the travel reservation. */ - @SerializedName("passengers") - List passengers; + /** Required. Arrival airport IATA code. */ + public Builder setAirport(String airport) { + this.airport = airport; + return this; + } - /** The phone number of the lodging location. */ - @SerializedName("property_phone_number") - String propertyPhoneNumber; + /** Arrival date/time. */ + public Builder setArrivesAt(Long arrivesAt) { + this.arrivesAt = arrivesAt; + return this; + } - /** The room class for this purchase. */ - @SerializedName("room_class") - String roomClass; + /** Arrival city. */ + public Builder setCity(String city) { + this.city = city; + return this; + } - /** The number of room nights. */ - @SerializedName("room_nights") - Long roomNights; + /** Arrival country. */ + public Builder setCountry(String country) { + this.country = country; + return this; + } - /** The total tax amount associating with the room reservation. */ - @SerializedName("total_room_tax_amount") - Long totalRoomTaxAmount; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Arrival#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** The total tax amount. */ - @SerializedName("total_tax_amount") - Long totalTaxAmount; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Arrival#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } - private Lodging( - Address address, - Long adults, - Affiliate affiliate, - String bookingNumber, - Category category, - Long checkinAt, - Long checkoutAt, - String customerServicePhoneNumber, - Long dailyRoomRateAmount, - Delivery delivery, - List extraCharges, - Map extraParams, - Boolean fireSafetyActCompliance, - String name, - Boolean noShow, - Long numberOfRooms, - List passengers, - String propertyPhoneNumber, - String roomClass, - Long roomNights, - Long totalRoomTaxAmount, - Long totalTaxAmount) { - this.address = address; - this.adults = adults; - this.affiliate = affiliate; - this.bookingNumber = bookingNumber; - this.category = category; - this.checkinAt = checkinAt; - this.checkoutAt = checkoutAt; - this.customerServicePhoneNumber = customerServicePhoneNumber; - this.dailyRoomRateAmount = dailyRoomRateAmount; - this.delivery = delivery; - this.extraCharges = extraCharges; - this.extraParams = extraParams; - this.fireSafetyActCompliance = fireSafetyActCompliance; - this.name = name; - this.noShow = noShow; - this.numberOfRooms = numberOfRooms; - this.passengers = passengers; - this.propertyPhoneNumber = propertyPhoneNumber; - this.roomClass = roomClass; - this.roomNights = roomNights; - this.totalRoomTaxAmount = totalRoomTaxAmount; - this.totalTaxAmount = totalTaxAmount; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Departure { + /** Required. Departure airport IATA code. */ + @SerializedName("airport") + String airport; - public static Builder builder() { - return new Builder(); - } + /** Departure city. */ + @SerializedName("city") + String city; - public static class Builder { - private Address address; + /** Departure country. */ + @SerializedName("country") + String country; - private Long adults; + /** Required. Departure date/time. */ + @SerializedName("departs_at") + Long departsAt; - private Affiliate affiliate; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private String bookingNumber; + private Departure( + String airport, + String city, + String country, + Long departsAt, + Map extraParams) { + this.airport = airport; + this.city = city; + this.country = country; + this.departsAt = departsAt; + this.extraParams = extraParams; + } - private Category category; + public static Builder builder() { + return new Builder(); + } - private Long checkinAt; + public static class Builder { + private String airport; - private Long checkoutAt; + private String city; - private String customerServicePhoneNumber; + private String country; - private Long dailyRoomRateAmount; + private Long departsAt; - private Delivery delivery; + private Map extraParams; - private List extraCharges; + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Departure build() { + return new PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Departure( + this.airport, this.city, this.country, this.departsAt, this.extraParams); + } - private Map extraParams; + /** Required. Departure airport IATA code. */ + public Builder setAirport(String airport) { + this.airport = airport; + return this; + } - private Boolean fireSafetyActCompliance; + /** Departure city. */ + public Builder setCity(String city) { + this.city = city; + return this; + } - private String name; + /** Departure country. */ + public Builder setCountry(String country) { + this.country = country; + return this; + } - private Boolean noShow; + /** Required. Departure date/time. */ + public Builder setDepartsAt(Long departsAt) { + this.departsAt = departsAt; + return this; + } - private Long numberOfRooms; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Departure#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - private List passengers; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Segment.Departure#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } - private String propertyPhoneNumber; + public enum ServiceClass implements ApiRequestParams.EnumParam { + @SerializedName("business") + BUSINESS("business"), - private String roomClass; + @SerializedName("economy") + ECONOMY("economy"), - private Long roomNights; + @SerializedName("first_class") + FIRST_CLASS("first_class"), - private Long totalRoomTaxAmount; + @SerializedName("premium_economy") + PREMIUM_ECONOMY("premium_economy"); - private Long totalTaxAmount; + @Getter(onMethod_ = {@Override}) + private final String value; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.Lodging build() { - return new PaymentIntentCreateParams.PaymentDetails.Lodging( - this.address, - this.adults, - this.affiliate, - this.bookingNumber, - this.category, - this.checkinAt, - this.checkoutAt, - this.customerServicePhoneNumber, - this.dailyRoomRateAmount, - this.delivery, - this.extraCharges, - this.extraParams, - this.fireSafetyActCompliance, - this.name, - this.noShow, - this.numberOfRooms, - this.passengers, - this.propertyPhoneNumber, - this.roomClass, - this.roomNights, - this.totalRoomTaxAmount, - this.totalTaxAmount); + ServiceClass(String value) { + this.value = value; + } } + } - /** The lodging location's address. */ - public Builder setAddress( - PaymentIntentCreateParams.PaymentDetails.Lodging.Address address) { - this.address = address; - return this; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Total { + /** Required. Total flight amount. */ + @SerializedName("amount") + Long amount; - /** The number of adults on the booking. */ - public Builder setAdults(Long adults) { - this.adults = adults; - return this; - } + /** Reason for credit. */ + @SerializedName("credit_reason") + CreditReason creditReason; - /** Affiliate details for this purchase. */ - public Builder setAffiliate( - PaymentIntentCreateParams.PaymentDetails.Lodging.Affiliate affiliate) { - this.affiliate = affiliate; - return this; - } + /** Total currency. */ + @SerializedName("currency") + String currency; - /** The booking number associated with the lodging reservation. */ - public Builder setBookingNumber(String bookingNumber) { - this.bookingNumber = bookingNumber; - return this; - } + /** Discount details. */ + @SerializedName("discounts") + Discounts discounts; - /** The lodging category. */ - public Builder setCategory( - PaymentIntentCreateParams.PaymentDetails.Lodging.Category category) { - this.category = category; - return this; - } + /** Additional charges. */ + @SerializedName("extra_charges") + List extraCharges; /** - * Required. Lodging check-in time. Measured in seconds since the Unix - * epoch. + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. */ - public Builder setCheckinAt(Long checkinAt) { - this.checkinAt = checkinAt; - return this; - } + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** - * Required. Lodging check-out time. Measured in seconds since the Unix - * epoch. - */ - public Builder setCheckoutAt(Long checkoutAt) { - this.checkoutAt = checkoutAt; - return this; - } + /** Tax breakdown. */ + @SerializedName("tax") + Tax tax; - /** The customer service phone number of the lodging company. */ - public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { - this.customerServicePhoneNumber = customerServicePhoneNumber; - return this; + private Total( + Long amount, + CreditReason creditReason, + String currency, + Discounts discounts, + List + extraCharges, + Map extraParams, + Tax tax) { + this.amount = amount; + this.creditReason = creditReason; + this.currency = currency; + this.discounts = discounts; + this.extraCharges = extraCharges; + this.extraParams = extraParams; + this.tax = tax; } - /** The daily lodging room rate. */ - public Builder setDailyRoomRateAmount(Long dailyRoomRateAmount) { - this.dailyRoomRateAmount = dailyRoomRateAmount; - return this; + public static Builder builder() { + return new Builder(); } - /** Delivery details for this purchase. */ - public Builder setDelivery( - PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery delivery) { - this.delivery = delivery; - return this; - } + public static class Builder { + private Long amount; - /** - * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.Lodging#extraCharges} for the field - * documentation. - */ - public Builder addExtraCharge( - PaymentIntentCreateParams.PaymentDetails.Lodging.ExtraCharge element) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.add(element); - return this; - } + private CreditReason creditReason; - /** - * Add all elements to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.Lodging#extraCharges} for the field - * documentation. - */ - public Builder addAllExtraCharge( - List elements) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.addAll(elements); - return this; - } + private String currency; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + private Discounts discounts; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + private List + extraCharges; - /** Indicates whether the lodging location is compliant with the Fire Safety Act. */ - public Builder setFireSafetyActCompliance(Boolean fireSafetyActCompliance) { - this.fireSafetyActCompliance = fireSafetyActCompliance; - return this; - } + private Map extraParams; - /** The name of the lodging location. */ - public Builder setName(String name) { - this.name = name; - return this; - } + private Tax tax; - /** - * Indicates if the customer did not keep their booking while failing to cancel the - * reservation. - */ - public Builder setNoShow(Boolean noShow) { - this.noShow = noShow; - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.FlightData.Total build() { + return new PaymentIntentCreateParams.PaymentDetails.FlightData.Total( + this.amount, + this.creditReason, + this.currency, + this.discounts, + this.extraCharges, + this.extraParams, + this.tax); + } - /** The number of rooms on the booking. */ - public Builder setNumberOfRooms(Long numberOfRooms) { - this.numberOfRooms = numberOfRooms; - return this; - } + /** Required. Total flight amount. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } - /** - * Add an element to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.Lodging#passengers} for the field documentation. - */ - public Builder addPassenger( - PaymentIntentCreateParams.PaymentDetails.Lodging.Passenger element) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); + /** Reason for credit. */ + public Builder setCreditReason( + PaymentIntentCreateParams.PaymentDetails.FlightData.Total.CreditReason creditReason) { + this.creditReason = creditReason; + return this; } - this.passengers.add(element); - return this; - } - /** - * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.Lodging#passengers} for the field documentation. - */ - public Builder addAllPassenger( - List elements) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); + /** Total currency. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; } - this.passengers.addAll(elements); - return this; - } - /** The phone number of the lodging location. */ - public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { - this.propertyPhoneNumber = propertyPhoneNumber; - return this; + /** Discount details. */ + public Builder setDiscounts( + PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Discounts discounts) { + this.discounts = discounts; + return this; + } + + /** + * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Total#extraCharges} for the field + * documentation. + */ + public Builder addExtraCharge( + PaymentIntentCreateParams.PaymentDetails.FlightData.Total.ExtraCharge element) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.add(element); + return this; + } + + /** + * Add all elements to `extraCharges` list. A list is initialized for the first + * `add/addAll` call, and subsequent calls adds additional elements to the original list. + * See {@link PaymentIntentCreateParams.PaymentDetails.FlightData.Total#extraCharges} for + * the field documentation. + */ + public Builder addAllExtraCharge( + List + elements) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.addAll(elements); + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.FlightData.Total#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.FlightData.Total#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Tax breakdown. */ + public Builder setTax(PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax tax) { + this.tax = tax; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Discounts { + /** Corporate client discount code. */ + @SerializedName("corporate_client_code") + String corporateClientCode; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Discounts(String corporateClientCode, Map extraParams) { + this.corporateClientCode = corporateClientCode; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String corporateClientCode; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Discounts build() { + return new PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Discounts( + this.corporateClientCode, this.extraParams); + } + + /** Corporate client discount code. */ + public Builder setCorporateClientCode(String corporateClientCode) { + this.corporateClientCode = corporateClientCode; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Discounts#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Discounts#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ExtraCharge { + /** Amount of additional charges. */ + @SerializedName("amount") + Long amount; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Type of additional charges. */ + @SerializedName("type") + Type type; + + private ExtraCharge(Long amount, Map extraParams, Type type) { + this.amount = amount; + this.extraParams = extraParams; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private Map extraParams; + + private Type type; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.FlightData.Total.ExtraCharge build() { + return new PaymentIntentCreateParams.PaymentDetails.FlightData.Total.ExtraCharge( + this.amount, this.extraParams, this.type); + } + + /** Amount of additional charges. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.ExtraCharge#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.ExtraCharge#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Type of additional charges. */ + public Builder setType( + PaymentIntentCreateParams.PaymentDetails.FlightData.Total.ExtraCharge.Type type) { + this.type = type; + return this; + } + } + + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("additional_fees") + ADDITIONAL_FEES("additional_fees"), + + @SerializedName("ancillary_service_charges") + ANCILLARY_SERVICE_CHARGES("ancillary_service_charges"), + + @SerializedName("exchange_fee") + EXCHANGE_FEE("exchange_fee"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Type(String value) { + this.value = value; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Tax { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Array of tax details. */ + @SerializedName("taxes") + List taxes; + + private Tax( + Map extraParams, + List taxes) { + this.extraParams = extraParams; + this.taxes = taxes; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private List + taxes; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax build() { + return new PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax( + this.extraParams, this.taxes); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Add an element to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax#taxes} for the field + * documentation. + */ + public Builder addTax( + PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax.InnerTax element) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.add(element); + return this; + } + + /** + * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax#taxes} for the field + * documentation. + */ + public Builder addAllTax( + List + elements) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.addAll(elements); + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class InnerTax { + /** Tax amount. */ + @SerializedName("amount") + Long amount; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Tax rate. */ + @SerializedName("rate") + Long rate; + + /** Type of tax. */ + @SerializedName("type") + String type; + + private InnerTax(Long amount, Map extraParams, Long rate, String type) { + this.amount = amount; + this.extraParams = extraParams; + this.rate = rate; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private Map extraParams; + + private Long rate; + + private String type; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax.InnerTax + build() { + return new PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax.InnerTax( + this.amount, this.extraParams, this.rate, this.type); + } + + /** Tax amount. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax.InnerTax#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.FlightData.Total.Tax.InnerTax#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Tax rate. */ + public Builder setRate(Long rate) { + this.rate = rate; + return this; + } + + /** Type of tax. */ + public Builder setType(String type) { + this.type = type; + return this; + } + } + } + } + + public enum CreditReason implements ApiRequestParams.EnumParam { + @SerializedName("other") + OTHER("other"), + + @SerializedName("partial_ticket_refund") + PARTIAL_TICKET_REFUND("partial_ticket_refund"), + + @SerializedName("passenger_transport_ancillary_cancellation") + PASSENGER_TRANSPORT_ANCILLARY_CANCELLATION("passenger_transport_ancillary_cancellation"), + + @SerializedName("ticket_and_ancillary_cancellation") + TICKET_AND_ANCILLARY_CANCELLATION("ticket_and_ancillary_cancellation"), + + @SerializedName("ticket_cancellation") + TICKET_CANCELLATION("ticket_cancellation"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + CreditReason(String value) { + this.value = value; + } + } + } + + public enum TransactionType implements ApiRequestParams.EnumParam { + @SerializedName("exchange_ticket") + EXCHANGE_TICKET("exchange_ticket"), + + @SerializedName("miscellaneous") + MISCELLANEOUS("miscellaneous"), + + @SerializedName("refund") + REFUND("refund"), + + @SerializedName("ticket_purchase") + TICKET_PURCHASE("ticket_purchase"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + TransactionType(String value) { + this.value = value; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Lodging { + /** The lodging location's address. */ + @SerializedName("address") + Address address; + + /** The number of adults on the booking. */ + @SerializedName("adults") + Long adults; + + /** Affiliate details for this purchase. */ + @SerializedName("affiliate") + Affiliate affiliate; + + /** The booking number associated with the lodging reservation. */ + @SerializedName("booking_number") + String bookingNumber; + + /** The lodging category. */ + @SerializedName("category") + Category category; + + /** + * Required. Lodging check-in time. Measured in seconds since the Unix epoch. + */ + @SerializedName("checkin_at") + Long checkinAt; + + /** + * Required. Lodging check-out time. Measured in seconds since the Unix + * epoch. + */ + @SerializedName("checkout_at") + Long checkoutAt; + + /** The customer service phone number of the lodging company. */ + @SerializedName("customer_service_phone_number") + String customerServicePhoneNumber; + + /** The daily lodging room rate. */ + @SerializedName("daily_room_rate_amount") + Long dailyRoomRateAmount; + + /** Delivery details for this purchase. */ + @SerializedName("delivery") + Delivery delivery; + + /** List of additional charges being billed. */ + @SerializedName("extra_charges") + List extraCharges; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Indicates whether the lodging location is compliant with the Fire Safety Act. */ + @SerializedName("fire_safety_act_compliance") + Boolean fireSafetyActCompliance; + + /** The name of the lodging location. */ + @SerializedName("name") + String name; + + /** + * Indicates if the customer did not keep their booking while failing to cancel the + * reservation. + */ + @SerializedName("no_show") + Boolean noShow; + + /** The number of rooms on the booking. */ + @SerializedName("number_of_rooms") + Long numberOfRooms; + + /** The details of the passengers in the travel reservation. */ + @SerializedName("passengers") + List passengers; + + /** The phone number of the lodging location. */ + @SerializedName("property_phone_number") + String propertyPhoneNumber; + + /** The room class for this purchase. */ + @SerializedName("room_class") + String roomClass; + + /** The number of room nights. */ + @SerializedName("room_nights") + Long roomNights; + + /** The total tax amount associating with the room reservation. */ + @SerializedName("total_room_tax_amount") + Long totalRoomTaxAmount; + + /** The total tax amount. */ + @SerializedName("total_tax_amount") + Long totalTaxAmount; + + private Lodging( + Address address, + Long adults, + Affiliate affiliate, + String bookingNumber, + Category category, + Long checkinAt, + Long checkoutAt, + String customerServicePhoneNumber, + Long dailyRoomRateAmount, + Delivery delivery, + List extraCharges, + Map extraParams, + Boolean fireSafetyActCompliance, + String name, + Boolean noShow, + Long numberOfRooms, + List passengers, + String propertyPhoneNumber, + String roomClass, + Long roomNights, + Long totalRoomTaxAmount, + Long totalTaxAmount) { + this.address = address; + this.adults = adults; + this.affiliate = affiliate; + this.bookingNumber = bookingNumber; + this.category = category; + this.checkinAt = checkinAt; + this.checkoutAt = checkoutAt; + this.customerServicePhoneNumber = customerServicePhoneNumber; + this.dailyRoomRateAmount = dailyRoomRateAmount; + this.delivery = delivery; + this.extraCharges = extraCharges; + this.extraParams = extraParams; + this.fireSafetyActCompliance = fireSafetyActCompliance; + this.name = name; + this.noShow = noShow; + this.numberOfRooms = numberOfRooms; + this.passengers = passengers; + this.propertyPhoneNumber = propertyPhoneNumber; + this.roomClass = roomClass; + this.roomNights = roomNights; + this.totalRoomTaxAmount = totalRoomTaxAmount; + this.totalTaxAmount = totalTaxAmount; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Address address; + + private Long adults; + + private Affiliate affiliate; + + private String bookingNumber; + + private Category category; + + private Long checkinAt; + + private Long checkoutAt; + + private String customerServicePhoneNumber; + + private Long dailyRoomRateAmount; + + private Delivery delivery; + + private List extraCharges; + + private Map extraParams; + + private Boolean fireSafetyActCompliance; + + private String name; + + private Boolean noShow; + + private Long numberOfRooms; + + private List passengers; + + private String propertyPhoneNumber; + + private String roomClass; + + private Long roomNights; + + private Long totalRoomTaxAmount; + + private Long totalTaxAmount; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.Lodging build() { + return new PaymentIntentCreateParams.PaymentDetails.Lodging( + this.address, + this.adults, + this.affiliate, + this.bookingNumber, + this.category, + this.checkinAt, + this.checkoutAt, + this.customerServicePhoneNumber, + this.dailyRoomRateAmount, + this.delivery, + this.extraCharges, + this.extraParams, + this.fireSafetyActCompliance, + this.name, + this.noShow, + this.numberOfRooms, + this.passengers, + this.propertyPhoneNumber, + this.roomClass, + this.roomNights, + this.totalRoomTaxAmount, + this.totalTaxAmount); + } + + /** The lodging location's address. */ + public Builder setAddress( + PaymentIntentCreateParams.PaymentDetails.Lodging.Address address) { + this.address = address; + return this; + } + + /** The number of adults on the booking. */ + public Builder setAdults(Long adults) { + this.adults = adults; + return this; + } + + /** Affiliate details for this purchase. */ + public Builder setAffiliate( + PaymentIntentCreateParams.PaymentDetails.Lodging.Affiliate affiliate) { + this.affiliate = affiliate; + return this; + } + + /** The booking number associated with the lodging reservation. */ + public Builder setBookingNumber(String bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } + + /** The lodging category. */ + public Builder setCategory( + PaymentIntentCreateParams.PaymentDetails.Lodging.Category category) { + this.category = category; + return this; + } + + /** + * Required. Lodging check-in time. Measured in seconds since the Unix + * epoch. + */ + public Builder setCheckinAt(Long checkinAt) { + this.checkinAt = checkinAt; + return this; + } + + /** + * Required. Lodging check-out time. Measured in seconds since the Unix + * epoch. + */ + public Builder setCheckoutAt(Long checkoutAt) { + this.checkoutAt = checkoutAt; + return this; + } + + /** The customer service phone number of the lodging company. */ + public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; + } + + /** The daily lodging room rate. */ + public Builder setDailyRoomRateAmount(Long dailyRoomRateAmount) { + this.dailyRoomRateAmount = dailyRoomRateAmount; + return this; + } + + /** Delivery details for this purchase. */ + public Builder setDelivery( + PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery delivery) { + this.delivery = delivery; + return this; + } + + /** + * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.Lodging#extraCharges} for the field + * documentation. + */ + public Builder addExtraCharge( + PaymentIntentCreateParams.PaymentDetails.Lodging.ExtraCharge element) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.add(element); + return this; + } + + /** + * Add all elements to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.Lodging#extraCharges} for the field + * documentation. + */ + public Builder addAllExtraCharge( + List elements) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.addAll(elements); + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Indicates whether the lodging location is compliant with the Fire Safety Act. */ + public Builder setFireSafetyActCompliance(Boolean fireSafetyActCompliance) { + this.fireSafetyActCompliance = fireSafetyActCompliance; + return this; + } + + /** The name of the lodging location. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** + * Indicates if the customer did not keep their booking while failing to cancel the + * reservation. + */ + public Builder setNoShow(Boolean noShow) { + this.noShow = noShow; + return this; + } + + /** The number of rooms on the booking. */ + public Builder setNumberOfRooms(Long numberOfRooms) { + this.numberOfRooms = numberOfRooms; + return this; + } + + /** + * Add an element to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.Lodging#passengers} for the field documentation. + */ + public Builder addPassenger( + PaymentIntentCreateParams.PaymentDetails.Lodging.Passenger element) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.add(element); + return this; + } + + /** + * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.Lodging#passengers} for the field documentation. + */ + public Builder addAllPassenger( + List elements) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.addAll(elements); + return this; + } + + /** The phone number of the lodging location. */ + public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { + this.propertyPhoneNumber = propertyPhoneNumber; + return this; + } + + /** The room class for this purchase. */ + public Builder setRoomClass(String roomClass) { + this.roomClass = roomClass; + return this; + } + + /** The number of room nights. */ + public Builder setRoomNights(Long roomNights) { + this.roomNights = roomNights; + return this; + } + + /** The total tax amount associating with the room reservation. */ + public Builder setTotalRoomTaxAmount(Long totalRoomTaxAmount) { + this.totalRoomTaxAmount = totalRoomTaxAmount; + return this; + } + + /** The total tax amount. */ + public Builder setTotalTaxAmount(Long totalTaxAmount) { + this.totalTaxAmount = totalTaxAmount; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Address { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + String city; + + /** + * Two-letter country code (ISO + * 3166-1 alpha-2). + */ + @SerializedName("country") + String country; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Address line 1, such as the street, PO Box, or company name. */ + @SerializedName("line1") + String line1; + + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; + + /** ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; + + private Address( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String city; + + private String country; + + private Map extraParams; + + private String line1; + + private String line2; + + private String postalCode; + + private String state; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.Lodging.Address build() { + return new PaymentIntentCreateParams.PaymentDetails.Lodging.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } + + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO + * 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging.Address#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging.Address#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } + + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } + + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } + + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Affiliate { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Required. The name of the affiliate that originated the purchase. */ + @SerializedName("name") + String name; + + private Affiliate(Map extraParams, String name) { + this.extraParams = extraParams; + this.name = name; } - /** The room class for this purchase. */ - public Builder setRoomClass(String roomClass) { - this.roomClass = roomClass; - return this; + public static Builder builder() { + return new Builder(); } - /** The number of room nights. */ - public Builder setRoomNights(Long roomNights) { - this.roomNights = roomNights; - return this; + public static class Builder { + private Map extraParams; + + private String name; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.Lodging.Affiliate build() { + return new PaymentIntentCreateParams.PaymentDetails.Lodging.Affiliate( + this.extraParams, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging.Affiliate#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging.Affiliate#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Required. The name of the affiliate that originated the purchase. */ + public Builder setName(String name) { + this.name = name; + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Delivery { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The delivery method for the payment. */ + @SerializedName("mode") + Mode mode; + + /** Details of the recipient. */ + @SerializedName("recipient") + Recipient recipient; + + private Delivery(Map extraParams, Mode mode, Recipient recipient) { + this.extraParams = extraParams; + this.mode = mode; + this.recipient = recipient; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Mode mode; + + private Recipient recipient; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery build() { + return new PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery( + this.extraParams, this.mode, this.recipient); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The delivery method for the payment. */ + public Builder setMode( + PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery.Mode mode) { + this.mode = mode; + return this; + } + + /** Details of the recipient. */ + public Builder setRecipient( + PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery.Recipient recipient) { + this.recipient = recipient; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Recipient { + /** The email of the recipient the ticket is delivered to. */ + @SerializedName("email") + String email; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The name of the recipient the ticket is delivered to. */ + @SerializedName("name") + String name; + + /** The phone number of the recipient the ticket is delivered to. */ + @SerializedName("phone") + String phone; + + private Recipient( + String email, Map extraParams, String name, String phone) { + this.email = email; + this.extraParams = extraParams; + this.name = name; + this.phone = phone; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String email; + + private Map extraParams; + + private String name; + + private String phone; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery.Recipient build() { + return new PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery.Recipient( + this.email, this.extraParams, this.name, this.phone); + } + + /** The email of the recipient the ticket is delivered to. */ + public Builder setEmail(String email) { + this.email = email; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The name of the recipient the ticket is delivered to. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** The phone number of the recipient the ticket is delivered to. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } + } } - /** The total tax amount associating with the room reservation. */ - public Builder setTotalRoomTaxAmount(Long totalRoomTaxAmount) { - this.totalRoomTaxAmount = totalRoomTaxAmount; - return this; - } + public enum Mode implements ApiRequestParams.EnumParam { + @SerializedName("email") + EMAIL("email"), + + @SerializedName("phone") + PHONE("phone"), + + @SerializedName("pickup") + PICKUP("pickup"), - /** The total tax amount. */ - public Builder setTotalTaxAmount(Long totalTaxAmount) { - this.totalTaxAmount = totalTaxAmount; - return this; + @SerializedName("post") + POST("post"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Mode(String value) { + this.value = value; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Address { - /** City, district, suburb, town, or village. */ - @SerializedName("city") - String city; - - /** - * Two-letter country code (ISO - * 3166-1 alpha-2). - */ - @SerializedName("country") - String country; - + public static class Passenger { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -11530,40 +13316,15 @@ public static class Address { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Address line 1, such as the street, PO Box, or company name. */ - @SerializedName("line1") - String line1; - - /** Address line 2, such as the apartment, suite, unit, or building. */ - @SerializedName("line2") - String line2; - - /** ZIP or postal code. */ - @SerializedName("postal_code") - String postalCode; - /** - * State, county, province, or region (ISO 3166-2). + * Required. Full name of the person or entity on the lodging reservation. */ - @SerializedName("state") - String state; + @SerializedName("name") + String name; - private Address( - String city, - String country, - Map extraParams, - String line1, - String line2, - String postalCode, - String state) { - this.city = city; - this.country = country; + private Passenger(Map extraParams, String name) { this.extraParams = extraParams; - this.line1 = line1; - this.line2 = line2; - this.postalCode = postalCode; - this.state = state; + this.name = name; } public static Builder builder() { @@ -11571,51 +13332,20 @@ public static Builder builder() { } public static class Builder { - private String city; - - private String country; - private Map extraParams; - private String line1; - - private String line2; - - private String postalCode; - - private String state; + private String name; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.Lodging.Address build() { - return new PaymentIntentCreateParams.PaymentDetails.Lodging.Address( - this.city, - this.country, - this.extraParams, - this.line1, - this.line2, - this.postalCode, - this.state); - } - - /** City, district, suburb, town, or village. */ - public Builder setCity(String city) { - this.city = city; - return this; - } - - /** - * Two-letter country code (ISO - * 3166-1 alpha-2). - */ - public Builder setCountry(String country) { - this.country = country; - return this; + public PaymentIntentCreateParams.PaymentDetails.Lodging.Passenger build() { + return new PaymentIntentCreateParams.PaymentDetails.Lodging.Passenger( + this.extraParams, this.name); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging.Address#extraParams} + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging.Passenger#extraParams} * for the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -11629,7 +13359,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging.Address#extraParams} + * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging.Passenger#extraParams} * for the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -11640,322 +13370,393 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Address line 1, such as the street, PO Box, or company name. */ - public Builder setLine1(String line1) { - this.line1 = line1; + /** + * Required. Full name of the person or entity on the lodging + * reservation. + */ + public Builder setName(String name) { + this.name = name; return this; } + } + } - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(String line2) { - this.line2 = line2; - return this; - } + public enum Category implements ApiRequestParams.EnumParam { + @SerializedName("hotel") + HOTEL("hotel"), - /** ZIP or postal code. */ - public Builder setPostalCode(String postalCode) { - this.postalCode = postalCode; - return this; - } + @SerializedName("vacation_rental") + VACATION_RENTAL("vacation_rental"); - /** - * State, county, province, or region (ISO 3166-2). - */ - public Builder setState(String state) { - this.state = state; - return this; - } + @Getter(onMethod_ = {@Override}) + private final String value; + + Category(String value) { + this.value = value; } } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Affiliate { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public enum ExtraCharge implements ApiRequestParams.EnumParam { + @SerializedName("gift_shop") + GIFT_SHOP("gift_shop"), - /** Required. The name of the affiliate that originated the purchase. */ - @SerializedName("name") - String name; + @SerializedName("laundry") + LAUNDRY("laundry"), - private Affiliate(Map extraParams, String name) { - this.extraParams = extraParams; - this.name = name; + @SerializedName("mini_bar") + MINI_BAR("mini_bar"), + + @SerializedName("other") + OTHER("other"), + + @SerializedName("restaurant") + RESTAURANT("restaurant"), + + @SerializedName("telephone") + TELEPHONE("telephone"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ExtraCharge(String value) { + this.value = value; } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class LodgingData { + /** Accommodation details for the lodging. */ + @SerializedName("accommodation") + Accommodation accommodation; + + /** Affiliate details if applicable. */ + @SerializedName("affiliate") + Affiliate affiliate; + + /** Booking confirmation number for the lodging. */ + @SerializedName("booking_number") + String bookingNumber; + + /** Required. Check-in date. */ + @SerializedName("checkin_at") + Long checkinAt; + + /** Required. Check-out date. */ + @SerializedName("checkout_at") + Long checkoutAt; + + /** Customer service phone number for the lodging company. */ + @SerializedName("customer_service_phone_number") + String customerServicePhoneNumber; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Whether the lodging is compliant with any hotel fire safety regulations. */ + @SerializedName("fire_safety_act_compliance_indicator") + Boolean fireSafetyActComplianceIndicator; + + /** List of guests for the lodging. */ + @SerializedName("guests") + List guests; + + /** Host details for the lodging. */ + @SerializedName("host") + Host host; + + /** List of insurances for the lodging. */ + @SerializedName("insurances") + List insurances; + + /** Whether the renter is a no-show. */ + @SerializedName("no_show_indicator") + Boolean noShowIndicator; + + /** Renter ID number for the lodging. */ + @SerializedName("renter_id_number") + String renterIdNumber; + + /** Renter name for the lodging. */ + @SerializedName("renter_name") + String renterName; - public static Builder builder() { - return new Builder(); - } + /** Required. Total details for the lodging. */ + @SerializedName("total") + Total total; - public static class Builder { - private Map extraParams; + private LodgingData( + Accommodation accommodation, + Affiliate affiliate, + String bookingNumber, + Long checkinAt, + Long checkoutAt, + String customerServicePhoneNumber, + Map extraParams, + Boolean fireSafetyActComplianceIndicator, + List guests, + Host host, + List insurances, + Boolean noShowIndicator, + String renterIdNumber, + String renterName, + Total total) { + this.accommodation = accommodation; + this.affiliate = affiliate; + this.bookingNumber = bookingNumber; + this.checkinAt = checkinAt; + this.checkoutAt = checkoutAt; + this.customerServicePhoneNumber = customerServicePhoneNumber; + this.extraParams = extraParams; + this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; + this.guests = guests; + this.host = host; + this.insurances = insurances; + this.noShowIndicator = noShowIndicator; + this.renterIdNumber = renterIdNumber; + this.renterName = renterName; + this.total = total; + } - private String name; + public static Builder builder() { + return new Builder(); + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.Lodging.Affiliate build() { - return new PaymentIntentCreateParams.PaymentDetails.Lodging.Affiliate( - this.extraParams, this.name); - } + public static class Builder { + private Accommodation accommodation; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging.Affiliate#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + private Affiliate affiliate; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging.Affiliate#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + private String bookingNumber; - /** Required. The name of the affiliate that originated the purchase. */ - public Builder setName(String name) { - this.name = name; - return this; - } - } - } + private Long checkinAt; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Delivery { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private Long checkoutAt; - /** The delivery method for the payment. */ - @SerializedName("mode") - Mode mode; + private String customerServicePhoneNumber; - /** Details of the recipient. */ - @SerializedName("recipient") - Recipient recipient; + private Map extraParams; - private Delivery(Map extraParams, Mode mode, Recipient recipient) { - this.extraParams = extraParams; - this.mode = mode; - this.recipient = recipient; - } + private Boolean fireSafetyActComplianceIndicator; - public static Builder builder() { - return new Builder(); - } + private List guests; - public static class Builder { - private Map extraParams; + private Host host; - private Mode mode; + private List insurances; - private Recipient recipient; + private Boolean noShowIndicator; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery build() { - return new PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery( - this.extraParams, this.mode, this.recipient); - } + private String renterIdNumber; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + private String renterName; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + private Total total; - /** The delivery method for the payment. */ - public Builder setMode( - PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery.Mode mode) { - this.mode = mode; - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.LodgingData build() { + return new PaymentIntentCreateParams.PaymentDetails.LodgingData( + this.accommodation, + this.affiliate, + this.bookingNumber, + this.checkinAt, + this.checkoutAt, + this.customerServicePhoneNumber, + this.extraParams, + this.fireSafetyActComplianceIndicator, + this.guests, + this.host, + this.insurances, + this.noShowIndicator, + this.renterIdNumber, + this.renterName, + this.total); + } - /** Details of the recipient. */ - public Builder setRecipient( - PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery.Recipient recipient) { - this.recipient = recipient; - return this; - } + /** Accommodation details for the lodging. */ + public Builder setAccommodation( + PaymentIntentCreateParams.PaymentDetails.LodgingData.Accommodation accommodation) { + this.accommodation = accommodation; + return this; } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Recipient { - /** The email of the recipient the ticket is delivered to. */ - @SerializedName("email") - String email; + /** Affiliate details if applicable. */ + public Builder setAffiliate( + PaymentIntentCreateParams.PaymentDetails.LodgingData.Affiliate affiliate) { + this.affiliate = affiliate; + return this; + } - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** Booking confirmation number for the lodging. */ + public Builder setBookingNumber(String bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } - /** The name of the recipient the ticket is delivered to. */ - @SerializedName("name") - String name; + /** Required. Check-in date. */ + public Builder setCheckinAt(Long checkinAt) { + this.checkinAt = checkinAt; + return this; + } - /** The phone number of the recipient the ticket is delivered to. */ - @SerializedName("phone") - String phone; + /** Required. Check-out date. */ + public Builder setCheckoutAt(Long checkoutAt) { + this.checkoutAt = checkoutAt; + return this; + } - private Recipient( - String email, Map extraParams, String name, String phone) { - this.email = email; - this.extraParams = extraParams; - this.name = name; - this.phone = phone; + /** Customer service phone number for the lodging company. */ + public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.put(key, value); + return this; + } - public static Builder builder() { - return new Builder(); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.putAll(map); + return this; + } - public static class Builder { - private String email; - - private Map extraParams; - - private String name; - - private String phone; - - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery.Recipient build() { - return new PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery.Recipient( - this.email, this.extraParams, this.name, this.phone); - } - - /** The email of the recipient the ticket is delivered to. */ - public Builder setEmail(String email) { - this.email = email; - return this; - } + /** Whether the lodging is compliant with any hotel fire safety regulations. */ + public Builder setFireSafetyActComplianceIndicator( + Boolean fireSafetyActComplianceIndicator) { + this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** + * Add an element to `guests` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData#guests} for the field documentation. + */ + public Builder addGuest( + PaymentIntentCreateParams.PaymentDetails.LodgingData.Guest element) { + if (this.guests == null) { + this.guests = new ArrayList<>(); + } + this.guests.add(element); + return this; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** + * Add all elements to `guests` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData#guests} for the field documentation. + */ + public Builder addAllGuest( + List elements) { + if (this.guests == null) { + this.guests = new ArrayList<>(); + } + this.guests.addAll(elements); + return this; + } - /** The name of the recipient the ticket is delivered to. */ - public Builder setName(String name) { - this.name = name; - return this; - } + /** Host details for the lodging. */ + public Builder setHost(PaymentIntentCreateParams.PaymentDetails.LodgingData.Host host) { + this.host = host; + return this; + } - /** The phone number of the recipient the ticket is delivered to. */ - public Builder setPhone(String phone) { - this.phone = phone; - return this; - } + /** + * Add an element to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData#insurances} for the field + * documentation. + */ + public Builder addInsurance( + PaymentIntentCreateParams.PaymentDetails.LodgingData.Insurance element) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); } + this.insurances.add(element); + return this; } - public enum Mode implements ApiRequestParams.EnumParam { - @SerializedName("email") - EMAIL("email"), - - @SerializedName("phone") - PHONE("phone"), + /** + * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData#insurances} for the field + * documentation. + */ + public Builder addAllInsurance( + List elements) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); + } + this.insurances.addAll(elements); + return this; + } - @SerializedName("pickup") - PICKUP("pickup"), + /** Whether the renter is a no-show. */ + public Builder setNoShowIndicator(Boolean noShowIndicator) { + this.noShowIndicator = noShowIndicator; + return this; + } - @SerializedName("post") - POST("post"); + /** Renter ID number for the lodging. */ + public Builder setRenterIdNumber(String renterIdNumber) { + this.renterIdNumber = renterIdNumber; + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** Renter name for the lodging. */ + public Builder setRenterName(String renterName) { + this.renterName = renterName; + return this; + } - Mode(String value) { - this.value = value; - } + /** Required. Total details for the lodging. */ + public Builder setTotal(PaymentIntentCreateParams.PaymentDetails.LodgingData.Total total) { + this.total = total; + return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Passenger { + public static class Accommodation { + /** Type of accommodation. */ + @SerializedName("accommodation_type") + AccommodationType accommodationType; + + /** Bed type. */ + @SerializedName("bed_type") + String bedType; + + /** Daily accommodation rate in cents. */ + @SerializedName("daily_rate_amount") + Long dailyRateAmount; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -11966,37 +13767,101 @@ public static class Passenger { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** - * Required. Full name of the person or entity on the lodging reservation. - */ - @SerializedName("name") - String name; + /** Number of nights. */ + @SerializedName("nights") + Long nights; - private Passenger(Map extraParams, String name) { + /** Number of rooms, cabanas, apartments, and so on. */ + @SerializedName("number_of_rooms") + Long numberOfRooms; + + /** Rate type. */ + @SerializedName("rate_type") + String rateType; + + /** Whether smoking is allowed. */ + @SerializedName("smoking_indicator") + Boolean smokingIndicator; + + private Accommodation( + AccommodationType accommodationType, + String bedType, + Long dailyRateAmount, + Map extraParams, + Long nights, + Long numberOfRooms, + String rateType, + Boolean smokingIndicator) { + this.accommodationType = accommodationType; + this.bedType = bedType; + this.dailyRateAmount = dailyRateAmount; this.extraParams = extraParams; - this.name = name; + this.nights = nights; + this.numberOfRooms = numberOfRooms; + this.rateType = rateType; + this.smokingIndicator = smokingIndicator; } public static Builder builder() { return new Builder(); } - public static class Builder { - private Map extraParams; + public static class Builder { + private AccommodationType accommodationType; + + private String bedType; + + private Long dailyRateAmount; + + private Map extraParams; + + private Long nights; + + private Long numberOfRooms; + + private String rateType; + + private Boolean smokingIndicator; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.LodgingData.Accommodation build() { + return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Accommodation( + this.accommodationType, + this.bedType, + this.dailyRateAmount, + this.extraParams, + this.nights, + this.numberOfRooms, + this.rateType, + this.smokingIndicator); + } + + /** Type of accommodation. */ + public Builder setAccommodationType( + PaymentIntentCreateParams.PaymentDetails.LodgingData.Accommodation.AccommodationType + accommodationType) { + this.accommodationType = accommodationType; + return this; + } - private String name; + /** Bed type. */ + public Builder setBedType(String bedType) { + this.bedType = bedType; + return this; + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.Lodging.Passenger build() { - return new PaymentIntentCreateParams.PaymentDetails.Lodging.Passenger( - this.extraParams, this.name); + /** Daily accommodation rate in cents. */ + public Builder setDailyRateAmount(Long dailyRateAmount) { + this.dailyRateAmount = dailyRateAmount; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging.Passenger#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Accommodation#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -12009,8 +13874,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.Lodging.Passenger#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Accommodation#extraParams} for the + * field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -12020,392 +13886,236 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Required. Full name of the person or entity on the lodging - * reservation. - */ - public Builder setName(String name) { - this.name = name; + /** Number of nights. */ + public Builder setNights(Long nights) { + this.nights = nights; return this; } - } - } - - public enum Category implements ApiRequestParams.EnumParam { - @SerializedName("hotel") - HOTEL("hotel"), - - @SerializedName("vacation_rental") - VACATION_RENTAL("vacation_rental"); - - @Getter(onMethod_ = {@Override}) - private final String value; - - Category(String value) { - this.value = value; - } - } - - public enum ExtraCharge implements ApiRequestParams.EnumParam { - @SerializedName("gift_shop") - GIFT_SHOP("gift_shop"), - - @SerializedName("laundry") - LAUNDRY("laundry"), - - @SerializedName("mini_bar") - MINI_BAR("mini_bar"), - - @SerializedName("other") - OTHER("other"), - @SerializedName("restaurant") - RESTAURANT("restaurant"), - - @SerializedName("telephone") - TELEPHONE("telephone"); + /** Number of rooms, cabanas, apartments, and so on. */ + public Builder setNumberOfRooms(Long numberOfRooms) { + this.numberOfRooms = numberOfRooms; + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** Rate type. */ + public Builder setRateType(String rateType) { + this.rateType = rateType; + return this; + } - ExtraCharge(String value) { - this.value = value; + /** Whether smoking is allowed. */ + public Builder setSmokingIndicator(Boolean smokingIndicator) { + this.smokingIndicator = smokingIndicator; + return this; + } } - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class LodgingData { - /** Accommodation details for the lodging. */ - @SerializedName("accommodation") - Accommodation accommodation; - - /** Affiliate details if applicable. */ - @SerializedName("affiliate") - Affiliate affiliate; - - /** Booking confirmation number for the lodging. */ - @SerializedName("booking_number") - String bookingNumber; - - /** Required. Check-in date. */ - @SerializedName("checkin_at") - Long checkinAt; - - /** Required. Check-out date. */ - @SerializedName("checkout_at") - Long checkoutAt; - - /** Customer service phone number for the lodging company. */ - @SerializedName("customer_service_phone_number") - String customerServicePhoneNumber; - - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) - * name in this param object. Effectively, this map is flattened to its parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; - - /** Whether the lodging is compliant with any hotel fire safety regulations. */ - @SerializedName("fire_safety_act_compliance_indicator") - Boolean fireSafetyActComplianceIndicator; - - /** List of guests for the lodging. */ - @SerializedName("guests") - List guests; - - /** Host details for the lodging. */ - @SerializedName("host") - Host host; - - /** List of insurances for the lodging. */ - @SerializedName("insurances") - List insurances; - - /** Whether the renter is a no-show. */ - @SerializedName("no_show_indicator") - Boolean noShowIndicator; - - /** Renter ID number for the lodging. */ - @SerializedName("renter_id_number") - String renterIdNumber; - - /** Renter name for the lodging. */ - @SerializedName("renter_name") - String renterName; - - /** Required. Total details for the lodging. */ - @SerializedName("total") - Total total; - - private LodgingData( - Accommodation accommodation, - Affiliate affiliate, - String bookingNumber, - Long checkinAt, - Long checkoutAt, - String customerServicePhoneNumber, - Map extraParams, - Boolean fireSafetyActComplianceIndicator, - List guests, - Host host, - List insurances, - Boolean noShowIndicator, - String renterIdNumber, - String renterName, - Total total) { - this.accommodation = accommodation; - this.affiliate = affiliate; - this.bookingNumber = bookingNumber; - this.checkinAt = checkinAt; - this.checkoutAt = checkoutAt; - this.customerServicePhoneNumber = customerServicePhoneNumber; - this.extraParams = extraParams; - this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; - this.guests = guests; - this.host = host; - this.insurances = insurances; - this.noShowIndicator = noShowIndicator; - this.renterIdNumber = renterIdNumber; - this.renterName = renterName; - this.total = total; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private Accommodation accommodation; - - private Affiliate affiliate; - - private String bookingNumber; - - private Long checkinAt; - - private Long checkoutAt; - - private String customerServicePhoneNumber; - - private Map extraParams; - - private Boolean fireSafetyActComplianceIndicator; - - private List guests; - - private Host host; - private List insurances; - - private Boolean noShowIndicator; - - private String renterIdNumber; - - private String renterName; - - private Total total; + public enum AccommodationType implements ApiRequestParams.EnumParam { + @SerializedName("apartment") + APARTMENT("apartment"), - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.LodgingData build() { - return new PaymentIntentCreateParams.PaymentDetails.LodgingData( - this.accommodation, - this.affiliate, - this.bookingNumber, - this.checkinAt, - this.checkoutAt, - this.customerServicePhoneNumber, - this.extraParams, - this.fireSafetyActComplianceIndicator, - this.guests, - this.host, - this.insurances, - this.noShowIndicator, - this.renterIdNumber, - this.renterName, - this.total); - } + @SerializedName("cabana") + CABANA("cabana"), - /** Accommodation details for the lodging. */ - public Builder setAccommodation( - PaymentIntentCreateParams.PaymentDetails.LodgingData.Accommodation accommodation) { - this.accommodation = accommodation; - return this; - } + @SerializedName("house") + HOUSE("house"), - /** Affiliate details if applicable. */ - public Builder setAffiliate( - PaymentIntentCreateParams.PaymentDetails.LodgingData.Affiliate affiliate) { - this.affiliate = affiliate; - return this; - } + @SerializedName("penthouse") + PENTHOUSE("penthouse"), - /** Booking confirmation number for the lodging. */ - public Builder setBookingNumber(String bookingNumber) { - this.bookingNumber = bookingNumber; - return this; - } + @SerializedName("room") + ROOM("room"), - /** Required. Check-in date. */ - public Builder setCheckinAt(Long checkinAt) { - this.checkinAt = checkinAt; - return this; - } + @SerializedName("standard") + STANDARD("standard"), - /** Required. Check-out date. */ - public Builder setCheckoutAt(Long checkoutAt) { - this.checkoutAt = checkoutAt; - return this; - } + @SerializedName("suite") + SUITE("suite"), - /** Customer service phone number for the lodging company. */ - public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { - this.customerServicePhoneNumber = customerServicePhoneNumber; - return this; - } + @SerializedName("villa") + VILLA("villa"); - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + @Getter(onMethod_ = {@Override}) + private final String value; + + AccommodationType(String value) { + this.value = value; } - this.extraParams.put(key, value); - return this; } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Affiliate { + /** Affiliate partner code. */ + @SerializedName("code") + String code; /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData#extraParams} for the - * field documentation. + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Affiliate partner name. */ + @SerializedName("name") + String name; + + private Affiliate(String code, Map extraParams, String name) { + this.code = code; + this.extraParams = extraParams; + this.name = name; } - /** Whether the lodging is compliant with any hotel fire safety regulations. */ - public Builder setFireSafetyActComplianceIndicator( - Boolean fireSafetyActComplianceIndicator) { - this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; - return this; + public static Builder builder() { + return new Builder(); } - /** - * Add an element to `guests` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData#guests} for the field documentation. - */ - public Builder addGuest( - PaymentIntentCreateParams.PaymentDetails.LodgingData.Guest element) { - if (this.guests == null) { - this.guests = new ArrayList<>(); + public static class Builder { + private String code; + + private Map extraParams; + + private String name; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.LodgingData.Affiliate build() { + return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Affiliate( + this.code, this.extraParams, this.name); } - this.guests.add(element); - return this; - } - /** - * Add all elements to `guests` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData#guests} for the field documentation. - */ - public Builder addAllGuest( - List elements) { - if (this.guests == null) { - this.guests = new ArrayList<>(); + /** Affiliate partner code. */ + public Builder setCode(String code) { + this.code = code; + return this; } - this.guests.addAll(elements); - return this; - } - /** Host details for the lodging. */ - public Builder setHost(PaymentIntentCreateParams.PaymentDetails.LodgingData.Host host) { - this.host = host; - return this; - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** - * Add an element to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData#insurances} for the field - * documentation. - */ - public Builder addInsurance( - PaymentIntentCreateParams.PaymentDetails.LodgingData.Insurance element) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Affiliate partner name. */ + public Builder setName(String name) { + this.name = name; + return this; } - this.insurances.add(element); - return this; } + } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Guest { /** - * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData#insurances} for the field - * documentation. + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. */ - public Builder addAllInsurance( - List elements) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); - } - this.insurances.addAll(elements); - return this; - } + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Whether the renter is a no-show. */ - public Builder setNoShowIndicator(Boolean noShowIndicator) { - this.noShowIndicator = noShowIndicator; - return this; + /** Required. Guest's full name. */ + @SerializedName("name") + String name; + + private Guest(Map extraParams, String name) { + this.extraParams = extraParams; + this.name = name; } - /** Renter ID number for the lodging. */ - public Builder setRenterIdNumber(String renterIdNumber) { - this.renterIdNumber = renterIdNumber; - return this; + public static Builder builder() { + return new Builder(); } - /** Renter name for the lodging. */ - public Builder setRenterName(String renterName) { - this.renterName = renterName; - return this; - } + public static class Builder { + private Map extraParams; + + private String name; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.LodgingData.Guest build() { + return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Guest( + this.extraParams, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData.Guest#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData.Guest#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** Required. Total details for the lodging. */ - public Builder setTotal(PaymentIntentCreateParams.PaymentDetails.LodgingData.Total total) { - this.total = total; - return this; + /** Required. Guest's full name. */ + public Builder setName(String name) { + this.name = name; + return this; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Accommodation { - /** Type of accommodation. */ - @SerializedName("accommodation_type") - AccommodationType accommodationType; - - /** Bed type. */ - @SerializedName("bed_type") - String bedType; + public static class Host { + /** Address of the host. */ + @SerializedName("address") + Address address; - /** Daily accommodation rate in cents. */ - @SerializedName("daily_rate_amount") - Long dailyRateAmount; + /** Host's country of domicile. */ + @SerializedName("country_of_domicile") + String countryOfDomicile; /** * Map of extra parameters for custom features not available in this client library. The @@ -12417,39 +14127,49 @@ public static class Accommodation { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Number of nights. */ - @SerializedName("nights") - Long nights; + /** Reference number for the host. */ + @SerializedName("host_reference") + String hostReference; - /** Number of rooms, cabanas, apartments, and so on. */ - @SerializedName("number_of_rooms") - Long numberOfRooms; + /** Type of host. */ + @SerializedName("host_type") + HostType hostType; - /** Rate type. */ - @SerializedName("rate_type") - String rateType; + /** Name of the lodging property or host. */ + @SerializedName("name") + String name; - /** Whether smoking is allowed. */ - @SerializedName("smoking_indicator") - Boolean smokingIndicator; + /** Total number of reservations for the host. */ + @SerializedName("number_of_reservations") + Long numberOfReservations; - private Accommodation( - AccommodationType accommodationType, - String bedType, - Long dailyRateAmount, + /** Property phone number. */ + @SerializedName("property_phone_number") + String propertyPhoneNumber; + + /** Host's registration date. */ + @SerializedName("registered_at") + Long registeredAt; + + private Host( + Address address, + String countryOfDomicile, Map extraParams, - Long nights, - Long numberOfRooms, - String rateType, - Boolean smokingIndicator) { - this.accommodationType = accommodationType; - this.bedType = bedType; - this.dailyRateAmount = dailyRateAmount; + String hostReference, + HostType hostType, + String name, + Long numberOfReservations, + String propertyPhoneNumber, + Long registeredAt) { + this.address = address; + this.countryOfDomicile = countryOfDomicile; this.extraParams = extraParams; - this.nights = nights; - this.numberOfRooms = numberOfRooms; - this.rateType = rateType; - this.smokingIndicator = smokingIndicator; + this.hostReference = hostReference; + this.hostType = hostType; + this.name = name; + this.numberOfReservations = numberOfReservations; + this.propertyPhoneNumber = propertyPhoneNumber; + this.registeredAt = registeredAt; } public static Builder builder() { @@ -12457,61 +14177,56 @@ public static Builder builder() { } public static class Builder { - private AccommodationType accommodationType; - - private String bedType; + private Address address; - private Long dailyRateAmount; + private String countryOfDomicile; private Map extraParams; - private Long nights; + private String hostReference; - private Long numberOfRooms; + private HostType hostType; - private String rateType; + private String name; - private Boolean smokingIndicator; + private Long numberOfReservations; + + private String propertyPhoneNumber; + + private Long registeredAt; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.LodgingData.Accommodation build() { - return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Accommodation( - this.accommodationType, - this.bedType, - this.dailyRateAmount, + public PaymentIntentCreateParams.PaymentDetails.LodgingData.Host build() { + return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Host( + this.address, + this.countryOfDomicile, this.extraParams, - this.nights, - this.numberOfRooms, - this.rateType, - this.smokingIndicator); - } - - /** Type of accommodation. */ - public Builder setAccommodationType( - PaymentIntentCreateParams.PaymentDetails.LodgingData.Accommodation.AccommodationType - accommodationType) { - this.accommodationType = accommodationType; - return this; + this.hostReference, + this.hostType, + this.name, + this.numberOfReservations, + this.propertyPhoneNumber, + this.registeredAt); } - /** Bed type. */ - public Builder setBedType(String bedType) { - this.bedType = bedType; + /** Address of the host. */ + public Builder setAddress( + PaymentIntentCreateParams.PaymentDetails.LodgingData.Host.Address address) { + this.address = address; return this; } - /** Daily accommodation rate in cents. */ - public Builder setDailyRateAmount(Long dailyRateAmount) { - this.dailyRateAmount = dailyRateAmount; + /** Host's country of domicile. */ + public Builder setCountryOfDomicile(String countryOfDomicile) { + this.countryOfDomicile = countryOfDomicile; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Accommodation#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData.Host#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -12524,9 +14239,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Accommodation#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData.Host#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -12536,156 +14250,247 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Number of nights. */ - public Builder setNights(Long nights) { - this.nights = nights; + /** Reference number for the host. */ + public Builder setHostReference(String hostReference) { + this.hostReference = hostReference; + return this; + } + + /** Type of host. */ + public Builder setHostType( + PaymentIntentCreateParams.PaymentDetails.LodgingData.Host.HostType hostType) { + this.hostType = hostType; + return this; + } + + /** Name of the lodging property or host. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** Total number of reservations for the host. */ + public Builder setNumberOfReservations(Long numberOfReservations) { + this.numberOfReservations = numberOfReservations; + return this; + } + + /** Property phone number. */ + public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { + this.propertyPhoneNumber = propertyPhoneNumber; return this; } - /** Number of rooms, cabanas, apartments, and so on. */ - public Builder setNumberOfRooms(Long numberOfRooms) { - this.numberOfRooms = numberOfRooms; - return this; + /** Host's registration date. */ + public Builder setRegisteredAt(Long registeredAt) { + this.registeredAt = registeredAt; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Address { + /** Required. City, district, suburb, town, or village. */ + @SerializedName("city") + String city; + + /** + * Required. Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + String country; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** + * Required. Address line 1, such as the street, PO Box, or company name. + */ + @SerializedName("line1") + String line1; + + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; + + /** Required. ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; + + private Address( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; } - /** Rate type. */ - public Builder setRateType(String rateType) { - this.rateType = rateType; - return this; + public static Builder builder() { + return new Builder(); } - /** Whether smoking is allowed. */ - public Builder setSmokingIndicator(Boolean smokingIndicator) { - this.smokingIndicator = smokingIndicator; - return this; - } - } + public static class Builder { + private String city; - public enum AccommodationType implements ApiRequestParams.EnumParam { - @SerializedName("apartment") - APARTMENT("apartment"), + private String country; - @SerializedName("cabana") - CABANA("cabana"), + private Map extraParams; - @SerializedName("house") - HOUSE("house"), + private String line1; - @SerializedName("penthouse") - PENTHOUSE("penthouse"), + private String line2; - @SerializedName("room") - ROOM("room"), + private String postalCode; - @SerializedName("standard") - STANDARD("standard"), + private String state; - @SerializedName("suite") - SUITE("suite"), + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.LodgingData.Host.Address build() { + return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Host.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } - @SerializedName("villa") - VILLA("villa"); + /** Required. City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** + * Required. Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } - AccommodationType(String value) { - this.value = value; - } - } - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Host.Address#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Affiliate { - /** Affiliate partner code. */ - @SerializedName("code") - String code; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Host.Address#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** + * Required. Address line 1, such as the street, PO Box, or company + * name. + */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } - /** Affiliate partner name. */ - @SerializedName("name") - String name; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } - private Affiliate(String code, Map extraParams, String name) { - this.code = code; - this.extraParams = extraParams; - this.name = name; - } + /** Required. ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - public static Builder builder() { - return new Builder(); + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + } } - public static class Builder { - private String code; - - private Map extraParams; - - private String name; + public enum HostType implements ApiRequestParams.EnumParam { + @SerializedName("hostel") + HOSTEL("hostel"), - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.LodgingData.Affiliate build() { - return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Affiliate( - this.code, this.extraParams, this.name); - } + @SerializedName("hotel") + HOTEL("hotel"), - /** Affiliate partner code. */ - public Builder setCode(String code) { - this.code = code; - return this; - } + @SerializedName("owner") + OWNER("owner"), - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Affiliate#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + @SerializedName("rental_agency") + RENTAL_AGENCY("rental_agency"); - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Affiliate#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + @Getter(onMethod_ = {@Override}) + private final String value; - /** Affiliate partner name. */ - public Builder setName(String name) { - this.name = name; - return this; + HostType(String value) { + this.value = value; } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Guest { + public static class Insurance { + /** Required. Price of the insurance coverage in cents. */ + @SerializedName("amount") + Long amount; + + /** Currency of the insurance amount. */ + @SerializedName("currency") + String currency; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -12696,13 +14501,25 @@ public static class Guest { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Required. Guest's full name. */ - @SerializedName("name") - String name; + /** Name of the insurance company. */ + @SerializedName("insurance_company_name") + String insuranceCompanyName; - private Guest(Map extraParams, String name) { + /** Required. Type of insurance coverage. */ + @SerializedName("insurance_type") + InsuranceType insuranceType; + + private Insurance( + Long amount, + String currency, + Map extraParams, + String insuranceCompanyName, + InsuranceType insuranceType) { + this.amount = amount; + this.currency = currency; this.extraParams = extraParams; - this.name = name; + this.insuranceCompanyName = insuranceCompanyName; + this.insuranceType = insuranceType; } public static Builder builder() { @@ -12710,21 +14527,44 @@ public static Builder builder() { } public static class Builder { + private Long amount; + + private String currency; + private Map extraParams; - private String name; + private String insuranceCompanyName; + + private InsuranceType insuranceType; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.LodgingData.Guest build() { - return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Guest( - this.extraParams, this.name); + public PaymentIntentCreateParams.PaymentDetails.LodgingData.Insurance build() { + return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Insurance( + this.amount, + this.currency, + this.extraParams, + this.insuranceCompanyName, + this.insuranceType); + } + + /** Required. Price of the insurance coverage in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Currency of the insurance amount. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData.Guest#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Insurance#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -12737,8 +14577,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData.Guest#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Insurance#extraParams} for the + * field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -12748,24 +14589,65 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Required. Guest's full name. */ - public Builder setName(String name) { - this.name = name; + /** Name of the insurance company. */ + public Builder setInsuranceCompanyName(String insuranceCompanyName) { + this.insuranceCompanyName = insuranceCompanyName; + return this; + } + + /** Required. Type of insurance coverage. */ + public Builder setInsuranceType( + PaymentIntentCreateParams.PaymentDetails.LodgingData.Insurance.InsuranceType + insuranceType) { + this.insuranceType = insuranceType; return this; } } + + public enum InsuranceType implements ApiRequestParams.EnumParam { + @SerializedName("bankruptcy") + BANKRUPTCY("bankruptcy"), + + @SerializedName("cancelation") + CANCELATION("cancelation"), + + @SerializedName("emergency") + EMERGENCY("emergency"), + + @SerializedName("medical") + MEDICAL("medical"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + InsuranceType(String value) { + this.value = value; + } + } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Host { - /** Address of the host. */ - @SerializedName("address") - Address address; + public static class Total { + /** Required. Total price of the lodging reservation in cents. */ + @SerializedName("amount") + Long amount; - /** Host's country of domicile. */ - @SerializedName("country_of_domicile") - String countryOfDomicile; + /** Cash advances in cents. */ + @SerializedName("cash_advances") + Long cashAdvances; + + /** Currency of the total amount. */ + @SerializedName("currency") + String currency; + + /** Discount details for the lodging. */ + @SerializedName("discounts") + Discounts discounts; + + /** Additional charges for the lodging. */ + @SerializedName("extra_charges") + List extraCharges; /** * Map of extra parameters for custom features not available in this client library. The @@ -12777,49 +14659,32 @@ public static class Host { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Reference number for the host. */ - @SerializedName("host_reference") - String hostReference; - - /** Type of host. */ - @SerializedName("host_type") - HostType hostType; - - /** Name of the lodging property or host. */ - @SerializedName("name") - String name; - - /** Total number of reservations for the host. */ - @SerializedName("number_of_reservations") - Long numberOfReservations; - - /** Property phone number. */ - @SerializedName("property_phone_number") - String propertyPhoneNumber; + /** Prepaid amount in cents. */ + @SerializedName("prepaid_amount") + Long prepaidAmount; - /** Host's registration date. */ - @SerializedName("registered_at") - Long registeredAt; + /** Tax breakdown for the lodging reservation. */ + @SerializedName("tax") + Tax tax; - private Host( - Address address, - String countryOfDomicile, + private Total( + Long amount, + Long cashAdvances, + String currency, + Discounts discounts, + List + extraCharges, Map extraParams, - String hostReference, - HostType hostType, - String name, - Long numberOfReservations, - String propertyPhoneNumber, - Long registeredAt) { - this.address = address; - this.countryOfDomicile = countryOfDomicile; + Long prepaidAmount, + Tax tax) { + this.amount = amount; + this.cashAdvances = cashAdvances; + this.currency = currency; + this.discounts = discounts; + this.extraCharges = extraCharges; this.extraParams = extraParams; - this.hostReference = hostReference; - this.hostType = hostType; - this.name = name; - this.numberOfReservations = numberOfReservations; - this.propertyPhoneNumber = propertyPhoneNumber; - this.registeredAt = registeredAt; + this.prepaidAmount = prepaidAmount; + this.tax = tax; } public static Builder builder() { @@ -12827,55 +14692,96 @@ public static Builder builder() { } public static class Builder { - private Address address; - - private String countryOfDomicile; + private Long amount; - private Map extraParams; + private Long cashAdvances; - private String hostReference; + private String currency; - private HostType hostType; + private Discounts discounts; - private String name; + private List + extraCharges; - private Long numberOfReservations; + private Map extraParams; - private String propertyPhoneNumber; + private Long prepaidAmount; - private Long registeredAt; + private Tax tax; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.LodgingData.Host build() { - return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Host( - this.address, - this.countryOfDomicile, + public PaymentIntentCreateParams.PaymentDetails.LodgingData.Total build() { + return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Total( + this.amount, + this.cashAdvances, + this.currency, + this.discounts, + this.extraCharges, this.extraParams, - this.hostReference, - this.hostType, - this.name, - this.numberOfReservations, - this.propertyPhoneNumber, - this.registeredAt); + this.prepaidAmount, + this.tax); } - /** Address of the host. */ - public Builder setAddress( - PaymentIntentCreateParams.PaymentDetails.LodgingData.Host.Address address) { - this.address = address; + /** Required. Total price of the lodging reservation in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; return this; } - /** Host's country of domicile. */ - public Builder setCountryOfDomicile(String countryOfDomicile) { - this.countryOfDomicile = countryOfDomicile; + /** Cash advances in cents. */ + public Builder setCashAdvances(Long cashAdvances) { + this.cashAdvances = cashAdvances; + return this; + } + + /** Currency of the total amount. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; + } + + /** Discount details for the lodging. */ + public Builder setDiscounts( + PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Discounts discounts) { + this.discounts = discounts; + return this; + } + + /** + * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total#extraCharges} for the field + * documentation. + */ + public Builder addExtraCharge( + PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.ExtraCharge element) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.add(element); + return this; + } + + /** + * Add all elements to `extraCharges` list. A list is initialized for the first + * `add/addAll` call, and subsequent calls adds additional elements to the original list. + * See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData.Total#extraCharges} for + * the field documentation. + */ + public Builder addAllExtraCharge( + List + elements) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.addAll(elements); return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData.Host#extraParams} + * map. See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData.Total#extraParams} * for the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -12889,7 +14795,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData.Host#extraParams} + * map. See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData.Total#extraParams} * for the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -12900,57 +14806,115 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Reference number for the host. */ - public Builder setHostReference(String hostReference) { - this.hostReference = hostReference; + /** Prepaid amount in cents. */ + public Builder setPrepaidAmount(Long prepaidAmount) { + this.prepaidAmount = prepaidAmount; return this; } - /** Type of host. */ - public Builder setHostType( - PaymentIntentCreateParams.PaymentDetails.LodgingData.Host.HostType hostType) { - this.hostType = hostType; + /** Tax breakdown for the lodging reservation. */ + public Builder setTax( + PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax tax) { + this.tax = tax; return this; } + } - /** Name of the lodging property or host. */ - public Builder setName(String name) { - this.name = name; - return this; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Discounts { + /** Corporate client discount code. */ + @SerializedName("corporate_client_code") + String corporateClientCode; - /** Total number of reservations for the host. */ - public Builder setNumberOfReservations(Long numberOfReservations) { - this.numberOfReservations = numberOfReservations; - return this; + /** Coupon code. */ + @SerializedName("coupon") + String coupon; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Discounts( + String corporateClientCode, String coupon, Map extraParams) { + this.corporateClientCode = corporateClientCode; + this.coupon = coupon; + this.extraParams = extraParams; } - /** Property phone number. */ - public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { - this.propertyPhoneNumber = propertyPhoneNumber; - return this; + public static Builder builder() { + return new Builder(); } - /** Host's registration date. */ - public Builder setRegisteredAt(Long registeredAt) { - this.registeredAt = registeredAt; - return this; + public static class Builder { + private String corporateClientCode; + + private String coupon; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Discounts build() { + return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Discounts( + this.corporateClientCode, this.coupon, this.extraParams); + } + + /** Corporate client discount code. */ + public Builder setCorporateClientCode(String corporateClientCode) { + this.corporateClientCode = corporateClientCode; + return this; + } + + /** Coupon code. */ + public Builder setCoupon(String coupon) { + this.coupon = coupon; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Address { - /** Required. City, district, suburb, town, or village. */ - @SerializedName("city") - String city; - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - @SerializedName("country") - String country; + public static class ExtraCharge { + /** Amount of the extra charge in cents. */ + @SerializedName("amount") + Long amount; /** * Map of extra parameters for custom features not available in this client library. The @@ -12962,42 +14926,133 @@ public static class Address { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** - * Required. Address line 1, such as the street, PO Box, or company name. - */ - @SerializedName("line1") - String line1; + /** Type of extra charge. */ + @SerializedName("type") + Type type; - /** Address line 2, such as the apartment, suite, unit, or building. */ - @SerializedName("line2") - String line2; + private ExtraCharge(Long amount, Map extraParams, Type type) { + this.amount = amount; + this.extraParams = extraParams; + this.type = type; + } - /** Required. ZIP or postal code. */ - @SerializedName("postal_code") - String postalCode; + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private Map extraParams; + + private Type type; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.ExtraCharge build() { + return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.ExtraCharge( + this.amount, this.extraParams, this.type); + } + + /** Amount of the extra charge in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Type of extra charge. */ + public Builder setType( + PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.ExtraCharge.Type type) { + this.type = type; + return this; + } + } + + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("gift_shop") + GIFT_SHOP("gift_shop"), + @SerializedName("laundry") + LAUNDRY("laundry"), + + @SerializedName("mini_bar") + MINI_BAR("mini_bar"), + + @SerializedName("other") + OTHER("other"), + + @SerializedName("phone") + PHONE("phone"), + + @SerializedName("restaurant") + RESTAURANT("restaurant"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Type(String value) { + this.value = value; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Tax { /** - * State, county, province, or region (ISO 3166-2). + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. */ - @SerializedName("state") - String state; + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private Address( - String city, - String country, + /** Indicates whether the transaction is tax exempt. */ + @SerializedName("tax_exempt_indicator") + Boolean taxExemptIndicator; + + /** Tax details. */ + @SerializedName("taxes") + List taxes; + + private Tax( Map extraParams, - String line1, - String line2, - String postalCode, - String state) { - this.city = city; - this.country = country; + Boolean taxExemptIndicator, + List taxes) { this.extraParams = extraParams; - this.line1 = line1; - this.line2 = line2; - this.postalCode = postalCode; - this.state = state; + this.taxExemptIndicator = taxExemptIndicator; + this.taxes = taxes; } public static Builder builder() { @@ -13005,53 +15060,25 @@ public static Builder builder() { } public static class Builder { - private String city; - - private String country; - private Map extraParams; - private String line1; - - private String line2; - - private String postalCode; + private Boolean taxExemptIndicator; - private String state; + private List + taxes; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.LodgingData.Host.Address build() { - return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Host.Address( - this.city, - this.country, - this.extraParams, - this.line1, - this.line2, - this.postalCode, - this.state); - } - - /** Required. City, district, suburb, town, or village. */ - public Builder setCity(String city) { - this.city = city; - return this; - } - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - public Builder setCountry(String country) { - this.country = country; - return this; + public PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax build() { + return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax( + this.extraParams, this.taxExemptIndicator, this.taxes); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Host.Address#extraParams} for - * the field documentation. + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -13065,8 +15092,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Host.Address#extraParams} for - * the field documentation. + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the + * field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -13076,228 +15103,261 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Required. Address line 1, such as the street, PO Box, or company - * name. - */ - public Builder setLine1(String line1) { - this.line1 = line1; - return this; - } - - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(String line2) { - this.line2 = line2; + /** Indicates whether the transaction is tax exempt. */ + public Builder setTaxExemptIndicator(Boolean taxExemptIndicator) { + this.taxExemptIndicator = taxExemptIndicator; return this; } - /** Required. ZIP or postal code. */ - public Builder setPostalCode(String postalCode) { - this.postalCode = postalCode; + /** + * Add an element to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field + * documentation. + */ + public Builder addTax( + PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax element) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.add(element); return this; } /** - * State, county, province, or region (ISO 3166-2). + * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field + * documentation. */ - public Builder setState(String state) { - this.state = state; + public Builder addAllTax( + List + elements) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.addAll(elements); return this; } } - } - public enum HostType implements ApiRequestParams.EnumParam { - @SerializedName("hostel") - HOSTEL("hostel"), + @Getter + @EqualsAndHashCode(callSuper = false) + public static class InnerTax { + /** Tax amount in cents. */ + @SerializedName("amount") + Long amount; - @SerializedName("hotel") - HOTEL("hotel"), + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - @SerializedName("owner") - OWNER("owner"), + /** Tax rate. */ + @SerializedName("rate") + Long rate; - @SerializedName("rental_agency") - RENTAL_AGENCY("rental_agency"); + /** Type of tax applied. */ + @SerializedName("type") + String type; - @Getter(onMethod_ = {@Override}) - private final String value; + private InnerTax(Long amount, Map extraParams, Long rate, String type) { + this.amount = amount; + this.extraParams = extraParams; + this.rate = rate; + this.type = type; + } - HostType(String value) { - this.value = value; - } - } - } + public static Builder builder() { + return new Builder(); + } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Insurance { - /** Required. Price of the insurance coverage in cents. */ - @SerializedName("amount") - Long amount; + public static class Builder { + private Long amount; - /** Currency of the insurance amount. */ - @SerializedName("currency") - String currency; + private Map extraParams; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private Long rate; - /** Name of the insurance company. */ - @SerializedName("insurance_company_name") - String insuranceCompanyName; + private String type; - /** Required. Type of insurance coverage. */ - @SerializedName("insurance_type") - InsuranceType insuranceType; + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax + build() { + return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax( + this.amount, this.extraParams, this.rate, this.type); + } - private Insurance( - Long amount, - String currency, - Map extraParams, - String insuranceCompanyName, - InsuranceType insuranceType) { - this.amount = amount; - this.currency = currency; - this.extraParams = extraParams; - this.insuranceCompanyName = insuranceCompanyName; - this.insuranceType = insuranceType; - } + /** Tax amount in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Tax rate. */ + public Builder setRate(Long rate) { + this.rate = rate; + return this; + } - public static Builder builder() { - return new Builder(); + /** Type of tax applied. */ + public Builder setType(String type) { + this.type = type; + return this; + } + } + } } + } + } - public static class Builder { - private Long amount; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Account funding transaction details including sender and beneficiary information. */ + @SerializedName("account_funding") + Object accountFunding; - private String currency; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private Map extraParams; + /** The type of money services transaction. */ + @SerializedName("transaction_type") + ApiRequestParams.EnumParam transactionType; - private String insuranceCompanyName; + private MoneyServices( + Object accountFunding, + Map extraParams, + ApiRequestParams.EnumParam transactionType) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + this.transactionType = transactionType; + } - private InsuranceType insuranceType; + public static Builder builder() { + return new Builder(); + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.LodgingData.Insurance build() { - return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Insurance( - this.amount, - this.currency, - this.extraParams, - this.insuranceCompanyName, - this.insuranceType); - } + public static class Builder { + private Object accountFunding; - /** Required. Price of the insurance coverage in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + private Map extraParams; - /** Currency of the insurance amount. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; - } + private ApiRequestParams.EnumParam transactionType; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Insurance#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.MoneyServices build() { + return new PaymentIntentCreateParams.PaymentDetails.MoneyServices( + this.accountFunding, this.extraParams, this.transactionType); + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Insurance#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding( + PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { + this.accountFunding = accountFunding; + return this; + } - /** Name of the insurance company. */ - public Builder setInsuranceCompanyName(String insuranceCompanyName) { - this.insuranceCompanyName = insuranceCompanyName; - return this; - } + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding(EmptyParam accountFunding) { + this.accountFunding = accountFunding; + return this; + } - /** Required. Type of insurance coverage. */ - public Builder setInsuranceType( - PaymentIntentCreateParams.PaymentDetails.LodgingData.Insurance.InsuranceType - insuranceType) { - this.insuranceType = insuranceType; - return this; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.MoneyServices#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.put(key, value); + return this; } - public enum InsuranceType implements ApiRequestParams.EnumParam { - @SerializedName("bankruptcy") - BANKRUPTCY("bankruptcy"), - - @SerializedName("cancelation") - CANCELATION("cancelation"), - - @SerializedName("emergency") - EMERGENCY("emergency"), - - @SerializedName("medical") - MEDICAL("medical"); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentCreateParams.PaymentDetails.MoneyServices#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** The type of money services transaction. */ + public Builder setTransactionType( + PaymentIntentCreateParams.PaymentDetails.MoneyServices.TransactionType + transactionType) { + this.transactionType = transactionType; + return this; + } - InsuranceType(String value) { - this.value = value; - } + /** The type of money services transaction. */ + public Builder setTransactionType(EmptyParam transactionType) { + this.transactionType = transactionType; + return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Total { - /** Required. Total price of the lodging reservation in cents. */ - @SerializedName("amount") - Long amount; - - /** Cash advances in cents. */ - @SerializedName("cash_advances") - Long cashAdvances; - - /** Currency of the total amount. */ - @SerializedName("currency") - String currency; - - /** Discount details for the lodging. */ - @SerializedName("discounts") - Discounts discounts; + public static class AccountFunding { + /** ID of the Account representing the beneficiary in this account funding transaction. */ + @SerializedName("beneficiary_account") + String beneficiaryAccount; - /** Additional charges for the lodging. */ - @SerializedName("extra_charges") - List extraCharges; + /** Inline identity details for the beneficiary of this account funding transaction. */ + @SerializedName("beneficiary_details") + Object beneficiaryDetails; /** * Map of extra parameters for custom features not available in this client library. The @@ -13309,32 +15369,25 @@ public static class Total { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Prepaid amount in cents. */ - @SerializedName("prepaid_amount") - Long prepaidAmount; + /** ID of the Account representing the sender in this account funding transaction. */ + @SerializedName("sender_account") + String senderAccount; - /** Tax breakdown for the lodging reservation. */ - @SerializedName("tax") - Tax tax; + /** Inline identity details for the sender of this account funding transaction. */ + @SerializedName("sender_details") + Object senderDetails; - private Total( - Long amount, - Long cashAdvances, - String currency, - Discounts discounts, - List - extraCharges, + private AccountFunding( + String beneficiaryAccount, + Object beneficiaryDetails, Map extraParams, - Long prepaidAmount, - Tax tax) { - this.amount = amount; - this.cashAdvances = cashAdvances; - this.currency = currency; - this.discounts = discounts; - this.extraCharges = extraCharges; + String senderAccount, + Object senderDetails) { + this.beneficiaryAccount = beneficiaryAccount; + this.beneficiaryDetails = beneficiaryDetails; this.extraParams = extraParams; - this.prepaidAmount = prepaidAmount; - this.tax = tax; + this.senderAccount = senderAccount; + this.senderDetails = senderDetails; } public static Builder builder() { @@ -13342,97 +15395,53 @@ public static Builder builder() { } public static class Builder { - private Long amount; - - private Long cashAdvances; - - private String currency; - - private Discounts discounts; + private String beneficiaryAccount; - private List - extraCharges; + private Object beneficiaryDetails; private Map extraParams; - private Long prepaidAmount; - - private Tax tax; - - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.LodgingData.Total build() { - return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Total( - this.amount, - this.cashAdvances, - this.currency, - this.discounts, - this.extraCharges, - this.extraParams, - this.prepaidAmount, - this.tax); - } - - /** Required. Total price of the lodging reservation in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + private String senderAccount; - /** Cash advances in cents. */ - public Builder setCashAdvances(Long cashAdvances) { - this.cashAdvances = cashAdvances; - return this; - } + private Object senderDetails; - /** Currency of the total amount. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding build() { + return new PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding( + this.beneficiaryAccount, + this.beneficiaryDetails, + this.extraParams, + this.senderAccount, + this.senderDetails); } - /** Discount details for the lodging. */ - public Builder setDiscounts( - PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Discounts discounts) { - this.discounts = discounts; + /** ID of the Account representing the beneficiary in this account funding transaction. */ + public Builder setBeneficiaryAccount(String beneficiaryAccount) { + this.beneficiaryAccount = beneficiaryAccount; return this; } - /** - * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total#extraCharges} for the field - * documentation. - */ - public Builder addExtraCharge( - PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.ExtraCharge element) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.add(element); + /** Inline identity details for the beneficiary of this account funding transaction. */ + public Builder setBeneficiaryDetails( + PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails + beneficiaryDetails) { + this.beneficiaryDetails = beneficiaryDetails; return this; } - /** - * Add all elements to `extraCharges` list. A list is initialized for the first - * `add/addAll` call, and subsequent calls adds additional elements to the original list. - * See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData.Total#extraCharges} for - * the field documentation. - */ - public Builder addAllExtraCharge( - List - elements) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.addAll(elements); + /** Inline identity details for the beneficiary of this account funding transaction. */ + public Builder setBeneficiaryDetails(EmptyParam beneficiaryDetails) { + this.beneficiaryDetails = beneficiaryDetails; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData.Total#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -13445,8 +15454,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.LodgingData.Total#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -13456,30 +15466,41 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Prepaid amount in cents. */ - public Builder setPrepaidAmount(Long prepaidAmount) { - this.prepaidAmount = prepaidAmount; + /** ID of the Account representing the sender in this account funding transaction. */ + public Builder setSenderAccount(String senderAccount) { + this.senderAccount = senderAccount; return this; } - /** Tax breakdown for the lodging reservation. */ - public Builder setTax( - PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax tax) { - this.tax = tax; + /** Inline identity details for the sender of this account funding transaction. */ + public Builder setSenderDetails( + PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + senderDetails) { + this.senderDetails = senderDetails; + return this; + } + + /** Inline identity details for the sender of this account funding transaction. */ + public Builder setSenderDetails(EmptyParam senderDetails) { + this.senderDetails = senderDetails; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Discounts { - /** Corporate client discount code. */ - @SerializedName("corporate_client_code") - String corporateClientCode; + public static class BeneficiaryDetails { + /** Address. */ + @SerializedName("address") + Address address; - /** Coupon code. */ - @SerializedName("coupon") - String coupon; + /** Date of birth. */ + @SerializedName("date_of_birth") + DateOfBirth dateOfBirth; + + /** Email address. */ + @SerializedName("email") + String email; /** * Map of extra parameters for custom features not available in this client library. The @@ -13491,11 +15512,27 @@ public static class Discounts { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private Discounts( - String corporateClientCode, String coupon, Map extraParams) { - this.corporateClientCode = corporateClientCode; - this.coupon = coupon; + /** Full name. */ + @SerializedName("name") + String name; + + /** Phone number. */ + @SerializedName("phone") + String phone; + + private BeneficiaryDetails( + Address address, + DateOfBirth dateOfBirth, + String email, + Map extraParams, + String name, + String phone) { + this.address = address; + this.dateOfBirth = dateOfBirth; + this.email = email; this.extraParams = extraParams; + this.name = name; + this.phone = phone; } public static Builder builder() { @@ -13503,27 +15540,53 @@ public static Builder builder() { } public static class Builder { - private String corporateClientCode; + private Address address; - private String coupon; + private DateOfBirth dateOfBirth; + + private String email; private Map extraParams; + private String name; + + private String phone; + /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Discounts build() { - return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Discounts( - this.corporateClientCode, this.coupon, this.extraParams); + public PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails + build() { + return new PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails( + this.address, + this.dateOfBirth, + this.email, + this.extraParams, + this.name, + this.phone); } - /** Corporate client discount code. */ - public Builder setCorporateClientCode(String corporateClientCode) { - this.corporateClientCode = corporateClientCode; + /** Address. */ + public Builder setAddress( + PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.Address + address) { + this.address = address; return this; } - /** Coupon code. */ - public Builder setCoupon(String coupon) { - this.coupon = coupon; + /** Date of birth. */ + public Builder setDateOfBirth( + PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.DateOfBirth + dateOfBirth) { + this.dateOfBirth = dateOfBirth; + return this; + } + + /** Email address. */ + public Builder setEmail(String email) { + this.email = email; return this; } @@ -13531,8 +15594,8 @@ public Builder setCoupon(String coupon) { * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} for - * the field documentation. + * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -13546,8 +15609,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} for - * the field documentation. + * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -13556,128 +15619,308 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } + + /** Full name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** Phone number. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class ExtraCharge { - /** Amount of the extra charge in cents. */ - @SerializedName("amount") - Long amount; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Address { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + String city; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + String country; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Address line 1, such as the street, PO Box, or company name. */ + @SerializedName("line1") + String line1; + + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; + + /** ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; + + private Address( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String city; + + private String country; + + private Map extraParams; + + private String line1; + + private String line2; + + private String postalCode; + + private String state; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.Address + build() { + return new PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } + + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.Address#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.Address#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** Type of extra charge. */ - @SerializedName("type") - Type type; + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } - private ExtraCharge(Long amount, Map extraParams, Type type) { - this.amount = amount; - this.extraParams = extraParams; - this.type = type; - } + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } - public static Builder builder() { - return new Builder(); + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } + + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + } } - public static class Builder { - private Long amount; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class DateOfBirth { + /** Required. Day of birth, between 1 and 31. */ + @SerializedName("day") + Long day; - private Map extraParams; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private Type type; + /** Required. Month of birth, between 1 and 12. */ + @SerializedName("month") + Long month; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.ExtraCharge build() { - return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.ExtraCharge( - this.amount, this.extraParams, this.type); - } + /** Required. Four-digit year of birth. */ + @SerializedName("year") + Long year; - /** Amount of the extra charge in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; + private DateOfBirth(Long day, Map extraParams, Long month, Long year) { + this.day = day; + this.extraParams = extraParams; + this.month = month; + this.year = year; } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; + public static Builder builder() { + return new Builder(); } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + public static class Builder { + private Long day; - /** Type of extra charge. */ - public Builder setType( - PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.ExtraCharge.Type type) { - this.type = type; - return this; - } - } + private Map extraParams; - public enum Type implements ApiRequestParams.EnumParam { - @SerializedName("gift_shop") - GIFT_SHOP("gift_shop"), + private Long month; - @SerializedName("laundry") - LAUNDRY("laundry"), + private Long year; - @SerializedName("mini_bar") - MINI_BAR("mini_bar"), + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.DateOfBirth + build() { + return new PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.DateOfBirth( + this.day, this.extraParams, this.month, this.year); + } - @SerializedName("other") - OTHER("other"), + /** Required. Day of birth, between 1 and 31. */ + public Builder setDay(Long day) { + this.day = day; + return this; + } - @SerializedName("phone") - PHONE("phone"), + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - @SerializedName("restaurant") - RESTAURANT("restaurant"); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** Required. Month of birth, between 1 and 12. */ + public Builder setMonth(Long month) { + this.month = month; + return this; + } - Type(String value) { - this.value = value; + /** Required. Four-digit year of birth. */ + public Builder setYear(Long year) { + this.year = year; + return this; + } } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Tax { + public static class SenderDetails { + /** Address. */ + @SerializedName("address") + Address address; + + /** Date of birth. */ + @SerializedName("date_of_birth") + DateOfBirth dateOfBirth; + + /** Email address. */ + @SerializedName("email") + String email; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -13688,21 +15931,27 @@ public static class Tax { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Indicates whether the transaction is tax exempt. */ - @SerializedName("tax_exempt_indicator") - Boolean taxExemptIndicator; + /** Full name. */ + @SerializedName("name") + String name; - /** Tax details. */ - @SerializedName("taxes") - List taxes; + /** Phone number. */ + @SerializedName("phone") + String phone; - private Tax( + private SenderDetails( + Address address, + DateOfBirth dateOfBirth, + String email, Map extraParams, - Boolean taxExemptIndicator, - List taxes) { + String name, + String phone) { + this.address = address; + this.dateOfBirth = dateOfBirth; + this.email = email; this.extraParams = extraParams; - this.taxExemptIndicator = taxExemptIndicator; - this.taxes = taxes; + this.name = name; + this.phone = phone; } public static Builder builder() { @@ -13710,25 +15959,62 @@ public static Builder builder() { } public static class Builder { + private Address address; + + private DateOfBirth dateOfBirth; + + private String email; + private Map extraParams; - private Boolean taxExemptIndicator; + private String name; - private List - taxes; + private String phone; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax build() { - return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax( - this.extraParams, this.taxExemptIndicator, this.taxes); + public PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails + build() { + return new PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails( + this.address, + this.dateOfBirth, + this.email, + this.extraParams, + this.name, + this.phone); + } + + /** Address. */ + public Builder setAddress( + PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + .Address + address) { + this.address = address; + return this; + } + + /** Date of birth. */ + public Builder setDateOfBirth( + PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + .DateOfBirth + dateOfBirth) { + this.dateOfBirth = dateOfBirth; + return this; + } + + /** Email address. */ + public Builder setEmail(String email) { + this.email = email; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the - * field documentation. + * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -13742,8 +16028,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the - * field documentation. + * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -13753,50 +16039,32 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Indicates whether the transaction is tax exempt. */ - public Builder setTaxExemptIndicator(Boolean taxExemptIndicator) { - this.taxExemptIndicator = taxExemptIndicator; - return this; - } - - /** - * Add an element to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addTax( - PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax element) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.add(element); + /** Full name. */ + public Builder setName(String name) { + this.name = name; return this; } - /** - * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addAllTax( - List - elements) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.addAll(elements); + /** Phone number. */ + public Builder setPhone(String phone) { + this.phone = phone; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class InnerTax { - /** Tax amount in cents. */ - @SerializedName("amount") - Long amount; + public static class Address { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + String city; + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + String country; /** * Map of extra parameters for custom features not available in this client library. The @@ -13808,19 +16076,40 @@ public static class InnerTax { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Tax rate. */ - @SerializedName("rate") - Long rate; + /** Address line 1, such as the street, PO Box, or company name. */ + @SerializedName("line1") + String line1; - /** Type of tax applied. */ - @SerializedName("type") - String type; + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + String line2; - private InnerTax(Long amount, Map extraParams, Long rate, String type) { - this.amount = amount; + /** ZIP or postal code. */ + @SerializedName("postal_code") + String postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + String state; + + private Address( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; this.extraParams = extraParams; - this.rate = rate; - this.type = type; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; } public static Builder builder() { @@ -13828,24 +16117,47 @@ public static Builder builder() { } public static class Builder { - private Long amount; + private String city; + + private String country; private Map extraParams; - private Long rate; + private String line1; - private String type; + private String line2; + + private String postalCode; + + private String state; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax + public PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.Address build() { - return new PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax( - this.amount, this.extraParams, this.rate, this.type); + return new PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); } - /** Tax amount in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; return this; } @@ -13853,7 +16165,7 @@ public Builder setAmount(Long amount) { * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} + * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.Address#extraParams} * for the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -13868,7 +16180,7 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the * first `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentCreateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} + * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.Address#extraParams} * for the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -13879,175 +16191,136 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Tax rate. */ - public Builder setRate(Long rate) { - this.rate = rate; + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(String line1) { + this.line1 = line1; return this; } - /** Type of tax applied. */ - public Builder setType(String type) { - this.type = type; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; return this; } - } - } - } - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class MoneyServices { - /** Account funding transaction details including sender and beneficiary information. */ - @SerializedName("account_funding") - Object accountFunding; - - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) - * name in this param object. Effectively, this map is flattened to its parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; - - /** The type of money services transaction. */ - @SerializedName("transaction_type") - TransactionType transactionType; - - private MoneyServices( - Object accountFunding, Map extraParams, TransactionType transactionType) { - this.accountFunding = accountFunding; - this.extraParams = extraParams; - this.transactionType = transactionType; - } - public static Builder builder() { - return new Builder(); - } + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - public static class Builder { - private Object accountFunding; + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + } + } - private Map extraParams; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class DateOfBirth { + /** Required. Day of birth, between 1 and 31. */ + @SerializedName("day") + Long day; - private TransactionType transactionType; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.MoneyServices build() { - return new PaymentIntentCreateParams.PaymentDetails.MoneyServices( - this.accountFunding, this.extraParams, this.transactionType); - } + /** Required. Month of birth, between 1 and 12. */ + @SerializedName("month") + Long month; - /** Account funding transaction details including sender and beneficiary information. */ - public Builder setAccountFunding( - PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { - this.accountFunding = accountFunding; - return this; - } + /** Required. Four-digit year of birth. */ + @SerializedName("year") + Long year; - /** Account funding transaction details including sender and beneficiary information. */ - public Builder setAccountFunding(EmptyParam accountFunding) { - this.accountFunding = accountFunding; - return this; - } + private DateOfBirth(Long day, Map extraParams, Long month, Long year) { + this.day = day; + this.extraParams = extraParams; + this.month = month; + this.year = year; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.MoneyServices#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + public static Builder builder() { + return new Builder(); + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentCreateParams.PaymentDetails.MoneyServices#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + public static class Builder { + private Long day; - /** The type of money services transaction. */ - public Builder setTransactionType( - PaymentIntentCreateParams.PaymentDetails.MoneyServices.TransactionType - transactionType) { - this.transactionType = transactionType; - return this; - } - } + private Map extraParams; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class AccountFunding { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private Long month; - private AccountFunding(Map extraParams) { - this.extraParams = extraParams; - } + private Long year; - public static Builder builder() { - return new Builder(); - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.DateOfBirth + build() { + return new PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.DateOfBirth(this.day, this.extraParams, this.month, this.year); + } - public static class Builder { - private Map extraParams; + /** Required. Day of birth, between 1 and 31. */ + public Builder setDay(Long day) { + this.day = day; + return this; + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding build() { - return new PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding( - this.extraParams); - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** Required. Month of birth, between 1 and 12. */ + public Builder setMonth(Long month) { + this.month = month; + return this; + } + + /** Required. Four-digit year of birth. */ + public Builder setYear(Long year) { + this.year = year; + return this; + } } - this.extraParams.putAll(map); - return this; } } } @@ -26976,53 +29249,604 @@ public static class AccountFunding { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private AccountFunding(Map extraParams) { + /** Details for a liquid asset (crypto or security) funding transaction. */ + @SerializedName("liquid_asset") + Object liquidAsset; + + /** Details for a wallet funding transaction. */ + @SerializedName("wallet") + Wallet wallet; + + private AccountFunding( + Map extraParams, Object liquidAsset, Wallet wallet) { this.extraParams = extraParams; + this.liquidAsset = liquidAsset; + this.wallet = wallet; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Object liquidAsset; + + private Wallet wallet; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding(this.extraParams, this.liquidAsset, this.wallet); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Details for a liquid asset (crypto or security) funding transaction. */ + public Builder setLiquidAsset( + PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + .AccountFunding.LiquidAsset + liquidAsset) { + this.liquidAsset = liquidAsset; + return this; + } + + /** Details for a liquid asset (crypto or security) funding transaction. */ + public Builder setLiquidAsset(EmptyParam liquidAsset) { + this.liquidAsset = liquidAsset; + return this; + } + + /** Details for a wallet funding transaction. */ + public Builder setWallet( + PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + .AccountFunding.Wallet + wallet) { + this.wallet = wallet; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class LiquidAsset { + /** Details for a cryptocurrency liquid asset funding transaction. */ + @SerializedName("crypto") + Crypto crypto; + + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if the + * key is a root-level field (serialized) name in this param object. Effectively, this + * map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Details for a security liquid asset funding transaction. */ + @SerializedName("security") + Security security; + + private LiquidAsset( + Crypto crypto, Map extraParams, Security security) { + this.crypto = crypto; + this.extraParams = extraParams; + this.security = security; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Crypto crypto; + + private Map extraParams; + + private Security security; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset( + this.crypto, this.extraParams, this.security); + } + + /** Details for a cryptocurrency liquid asset funding transaction. */ + public Builder setCrypto( + PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + .AccountFunding.LiquidAsset.Crypto + crypto) { + this.crypto = crypto; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Details for a security liquid asset funding transaction. */ + public Builder setSecurity( + PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + .AccountFunding.LiquidAsset.Security + security) { + this.security = security; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Crypto { + /** The cryptocurrency currency code (e.g. BTC, ETH). */ + @SerializedName("currency_code") + String currencyCode; + + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Crypto(String currencyCode, Map extraParams) { + this.currencyCode = currencyCode; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String currencyCode; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Crypto + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Crypto( + this.currencyCode, this.extraParams); + } + + /** The cryptocurrency currency code (e.g. BTC, ETH). */ + public Builder setCurrencyCode(String currencyCode) { + this.currencyCode = currencyCode; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Crypto#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Crypto#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Security { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The security's ticker symbol (e.g. AAPL). */ + @SerializedName("ticker_symbol") + String tickerSymbol; + + private Security(Map extraParams, String tickerSymbol) { + this.extraParams = extraParams; + this.tickerSymbol = tickerSymbol; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String tickerSymbol; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Security + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Security( + this.extraParams, this.tickerSymbol); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Security#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Security#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The security's ticker symbol (e.g. AAPL). */ + public Builder setTickerSymbol(String tickerSymbol) { + this.tickerSymbol = tickerSymbol; + return this; + } + } + } } - public static Builder builder() { - return new Builder(); - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Wallet { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if the + * key is a root-level field (serialized) name in this param object. Effectively, this + * map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Details for a staged purchase. */ + @SerializedName("staged_purchase") + Object stagedPurchase; + + private Wallet(Map extraParams, Object stagedPurchase) { + this.extraParams = extraParams; + this.stagedPurchase = stagedPurchase; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Object stagedPurchase; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet(this.extraParams, this.stagedPurchase); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Details for a staged purchase. */ + public Builder setStagedPurchase( + PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + .AccountFunding.Wallet.StagedPurchase + stagedPurchase) { + this.stagedPurchase = stagedPurchase; + return this; + } + + /** Details for a staged purchase. */ + public Builder setStagedPurchase(EmptyParam stagedPurchase) { + this.stagedPurchase = stagedPurchase; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class StagedPurchase { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The merchant where the staged wallet purchase is made. */ + @SerializedName("merchant") + Merchant merchant; + + private StagedPurchase(Map extraParams, Merchant merchant) { + this.extraParams = extraParams; + this.merchant = merchant; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Merchant merchant; - public static class Builder { - private Map extraParams; + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase( + this.extraParams, this.merchant); + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails - .MoneyServices.AccountFunding - build() { - return new PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails - .MoneyServices.AccountFunding(this.extraParams); - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The merchant where the staged wallet purchase is made. */ + public Builder setMerchant( + PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant + merchant) { + this.merchant = merchant; + return this; + } } - this.extraParams.put(key, value); - return this; - } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the - * first `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Merchant { + /** + * Map of extra parameters for custom features not available in this client + * library. The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The merchant category code of the merchant. */ + @SerializedName("mcc") + String mcc; + + /** The merchant's name. */ + @SerializedName("name") + String name; + + private Merchant(Map extraParams, String mcc, String name) { + this.extraParams = extraParams; + this.mcc = mcc; + this.name = name; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String mcc; + + private String name; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant( + this.extraParams, this.mcc, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for + * the first `put/putAll` call, and subsequent calls add additional key/value + * pairs to the original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The merchant category code of the merchant. */ + public Builder setMcc(String mcc) { + this.mcc = mcc; + return this; + } + + /** The merchant's name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + } } - this.extraParams.putAll(map); - return this; } } } @@ -28429,8 +31253,19 @@ public static class AccountFunding { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private AccountFunding(Map extraParams) { + /** Details for a liquid asset (crypto or security) funding transaction. */ + @SerializedName("liquid_asset") + Object liquidAsset; + + /** Details for a wallet funding transaction. */ + @SerializedName("wallet") + Wallet wallet; + + private AccountFunding( + Map extraParams, Object liquidAsset, Wallet wallet) { this.extraParams = extraParams; + this.liquidAsset = liquidAsset; + this.wallet = wallet; } public static Builder builder() { @@ -28440,12 +31275,16 @@ public static Builder builder() { public static class Builder { private Map extraParams; + private Object liquidAsset; + + private Wallet wallet; + /** Finalize and obtain parameter instance from this builder. */ public PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails .MoneyServices.AccountFunding build() { return new PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails - .MoneyServices.AccountFunding(this.extraParams); + .MoneyServices.AccountFunding(this.extraParams, this.liquidAsset, this.wallet); } /** @@ -28477,6 +31316,543 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } + + /** Details for a liquid asset (crypto or security) funding transaction. */ + public Builder setLiquidAsset( + PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset + liquidAsset) { + this.liquidAsset = liquidAsset; + return this; + } + + /** Details for a liquid asset (crypto or security) funding transaction. */ + public Builder setLiquidAsset(EmptyParam liquidAsset) { + this.liquidAsset = liquidAsset; + return this; + } + + /** Details for a wallet funding transaction. */ + public Builder setWallet( + PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet + wallet) { + this.wallet = wallet; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class LiquidAsset { + /** Details for a cryptocurrency liquid asset funding transaction. */ + @SerializedName("crypto") + Crypto crypto; + + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if the + * key is a root-level field (serialized) name in this param object. Effectively, this + * map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Details for a security liquid asset funding transaction. */ + @SerializedName("security") + Security security; + + private LiquidAsset( + Crypto crypto, Map extraParams, Security security) { + this.crypto = crypto; + this.extraParams = extraParams; + this.security = security; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Crypto crypto; + + private Map extraParams; + + private Security security; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.LiquidAsset( + this.crypto, this.extraParams, this.security); + } + + /** Details for a cryptocurrency liquid asset funding transaction. */ + public Builder setCrypto( + PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Crypto + crypto) { + this.crypto = crypto; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Details for a security liquid asset funding transaction. */ + public Builder setSecurity( + PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Security + security) { + this.security = security; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Crypto { + /** The cryptocurrency currency code (e.g. BTC, ETH). */ + @SerializedName("currency_code") + String currencyCode; + + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Crypto(String currencyCode, Map extraParams) { + this.currencyCode = currencyCode; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String currencyCode; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Crypto + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Crypto( + this.currencyCode, this.extraParams); + } + + /** The cryptocurrency currency code (e.g. BTC, ETH). */ + public Builder setCurrencyCode(String currencyCode) { + this.currencyCode = currencyCode; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Crypto#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Crypto#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Security { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The security's ticker symbol (e.g. AAPL). */ + @SerializedName("ticker_symbol") + String tickerSymbol; + + private Security(Map extraParams, String tickerSymbol) { + this.extraParams = extraParams; + this.tickerSymbol = tickerSymbol; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String tickerSymbol; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Security + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Security( + this.extraParams, this.tickerSymbol); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Security#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Security#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The security's ticker symbol (e.g. AAPL). */ + public Builder setTickerSymbol(String tickerSymbol) { + this.tickerSymbol = tickerSymbol; + return this; + } + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Wallet { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if the + * key is a root-level field (serialized) name in this param object. Effectively, this + * map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Details for a staged purchase. */ + @SerializedName("staged_purchase") + Object stagedPurchase; + + private Wallet(Map extraParams, Object stagedPurchase) { + this.extraParams = extraParams; + this.stagedPurchase = stagedPurchase; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Object stagedPurchase; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.Wallet( + this.extraParams, this.stagedPurchase); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Details for a staged purchase. */ + public Builder setStagedPurchase( + PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase + stagedPurchase) { + this.stagedPurchase = stagedPurchase; + return this; + } + + /** Details for a staged purchase. */ + public Builder setStagedPurchase(EmptyParam stagedPurchase) { + this.stagedPurchase = stagedPurchase; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class StagedPurchase { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The merchant where the staged wallet purchase is made. */ + @SerializedName("merchant") + Merchant merchant; + + private StagedPurchase(Map extraParams, Merchant merchant) { + this.extraParams = extraParams; + this.merchant = merchant; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Merchant merchant; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase( + this.extraParams, this.merchant); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The merchant where the staged wallet purchase is made. */ + public Builder setMerchant( + PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant + merchant) { + this.merchant = merchant; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Merchant { + /** + * Map of extra parameters for custom features not available in this client + * library. The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The merchant category code of the merchant. */ + @SerializedName("mcc") + String mcc; + + /** The merchant's name. */ + @SerializedName("name") + String name; + + private Merchant(Map extraParams, String mcc, String name) { + this.extraParams = extraParams; + this.mcc = mcc; + this.name = name; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String mcc; + + private String name; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase + .Merchant(this.extraParams, this.mcc, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for + * the first `put/putAll` call, and subsequent calls add additional key/value + * pairs to the original map. See {@link + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The merchant category code of the merchant. */ + public Builder setMcc(String mcc) { + this.mcc = mcc; + return this; + } + + /** The merchant's name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + } + } + } } } } diff --git a/src/main/java/com/stripe/param/PaymentIntentDecrementAuthorizationParams.java b/src/main/java/com/stripe/param/PaymentIntentDecrementAuthorizationParams.java index 5338c99cebe..1e7486eee0a 100644 --- a/src/main/java/com/stripe/param/PaymentIntentDecrementAuthorizationParams.java +++ b/src/main/java/com/stripe/param/PaymentIntentDecrementAuthorizationParams.java @@ -600,6 +600,13 @@ public static class LineItem { @SerializedName("quantity") Long quantity; + /** + * The number of decimal places implied in the quantity. For example, if quantity is 10000 and + * quantity_precision is 2, the actual quantity is 100.00. Defaults to 0 if not provided. + */ + @SerializedName("quantity_precision") + Long quantityPrecision; + /** Contains information about the tax on the item. */ @SerializedName("tax") Tax tax; @@ -623,6 +630,7 @@ private LineItem( String productCode, String productName, Long quantity, + Long quantityPrecision, Tax tax, Long unitCost, String unitOfMeasure) { @@ -632,6 +640,7 @@ private LineItem( this.productCode = productCode; this.productName = productName; this.quantity = quantity; + this.quantityPrecision = quantityPrecision; this.tax = tax; this.unitCost = unitCost; this.unitOfMeasure = unitOfMeasure; @@ -654,6 +663,8 @@ public static class Builder { private Long quantity; + private Long quantityPrecision; + private Tax tax; private Long unitCost; @@ -669,6 +680,7 @@ public PaymentIntentDecrementAuthorizationParams.AmountDetails.LineItem build() this.productCode, this.productName, this.quantity, + this.quantityPrecision, this.tax, this.unitCost, this.unitOfMeasure); @@ -755,6 +767,16 @@ public Builder setQuantity(Long quantity) { return this; } + /** + * The number of decimal places implied in the quantity. For example, if quantity is 10000 + * and quantity_precision is 2, the actual quantity is 100.00. Defaults to 0 if not + * provided. + */ + public Builder setQuantityPrecision(Long quantityPrecision) { + this.quantityPrecision = quantityPrecision; + return this; + } + /** Contains information about the tax on the item. */ public Builder setTax( PaymentIntentDecrementAuthorizationParams.AmountDetails.LineItem.Tax tax) { @@ -956,9 +978,14 @@ public static class Card { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private Card(String commodityCode, Map extraParams) { + /** Fleet data for this line item. */ + @SerializedName("fleet_data") + FleetData fleetData; + + private Card(String commodityCode, Map extraParams, FleetData fleetData) { this.commodityCode = commodityCode; this.extraParams = extraParams; + this.fleetData = fleetData; } public static Builder builder() { @@ -970,12 +997,14 @@ public static class Builder { private Map extraParams; + private FleetData fleetData; + /** Finalize and obtain parameter instance from this builder. */ public PaymentIntentDecrementAuthorizationParams.AmountDetails.LineItem .PaymentMethodOptions.Card build() { return new PaymentIntentDecrementAuthorizationParams.AmountDetails.LineItem - .PaymentMethodOptions.Card(this.commodityCode, this.extraParams); + .PaymentMethodOptions.Card(this.commodityCode, this.extraParams, this.fleetData); } /** @@ -1016,6 +1045,268 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } + + /** Fleet data for this line item. */ + public Builder setFleetData( + PaymentIntentDecrementAuthorizationParams.AmountDetails.LineItem + .PaymentMethodOptions.Card.FleetData + fleetData) { + this.fleetData = fleetData; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class FleetData { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Required. The type of product being purchased at this line item. */ + @SerializedName("product_type") + ProductType productType; + + /** The type of service received at the acceptor location. */ + @SerializedName("service_type") + ServiceType serviceType; + + private FleetData( + Map extraParams, ProductType productType, ServiceType serviceType) { + this.extraParams = extraParams; + this.productType = productType; + this.serviceType = serviceType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private ProductType productType; + + private ServiceType serviceType; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentDecrementAuthorizationParams.AmountDetails.LineItem + .PaymentMethodOptions.Card.FleetData + build() { + return new PaymentIntentDecrementAuthorizationParams.AmountDetails.LineItem + .PaymentMethodOptions.Card.FleetData( + this.extraParams, this.productType, this.serviceType); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentDecrementAuthorizationParams.AmountDetails.LineItem.PaymentMethodOptions.Card.FleetData#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentDecrementAuthorizationParams.AmountDetails.LineItem.PaymentMethodOptions.Card.FleetData#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. The type of product being purchased at this line item. + */ + public Builder setProductType( + PaymentIntentDecrementAuthorizationParams.AmountDetails.LineItem + .PaymentMethodOptions.Card.FleetData.ProductType + productType) { + this.productType = productType; + return this; + } + + /** The type of service received at the acceptor location. */ + public Builder setServiceType( + PaymentIntentDecrementAuthorizationParams.AmountDetails.LineItem + .PaymentMethodOptions.Card.FleetData.ServiceType + serviceType) { + this.serviceType = serviceType; + return this; + } + } + + public enum ProductType implements ApiRequestParams.EnumParam { + @SerializedName("air_conditioning_service") + AIR_CONDITIONING_SERVICE("air_conditioning_service"), + + @SerializedName("alcohol") + ALCOHOL("alcohol"), + + @SerializedName("aviation_fuel_premium") + AVIATION_FUEL_PREMIUM("aviation_fuel_premium"), + + @SerializedName("aviation_fuel_regular") + AVIATION_FUEL_REGULAR("aviation_fuel_regular"), + + @SerializedName("car_care_detailing") + CAR_CARE_DETAILING("car_care_detailing"), + + @SerializedName("compressed_natural_gas") + COMPRESSED_NATURAL_GAS("compressed_natural_gas"), + + @SerializedName("deli") + DELI("deli"), + + @SerializedName("food_service") + FOOD_SERVICE("food_service"), + + @SerializedName("green_gasoline_mid_plus") + GREEN_GASOLINE_MID_PLUS("green_gasoline_mid_plus"), + + @SerializedName("green_gasoline_premium_super") + GREEN_GASOLINE_PREMIUM_SUPER("green_gasoline_premium_super"), + + @SerializedName("green_gasoline_regular") + GREEN_GASOLINE_REGULAR("green_gasoline_regular"), + + @SerializedName("grocery") + GROCERY("grocery"), + + @SerializedName("liquid_natural_gas") + LIQUID_NATURAL_GAS("liquid_natural_gas"), + + @SerializedName("liquid_propane_gas") + LIQUID_PROPANE_GAS("liquid_propane_gas"), + + @SerializedName("lodging") + LODGING("lodging"), + + @SerializedName("marine_diesel") + MARINE_DIESEL("marine_diesel"), + + @SerializedName("marine_fuel") + MARINE_FUEL("marine_fuel"), + + @SerializedName("merchandise") + MERCHANDISE("merchandise"), + + @SerializedName("mid_plus") + MID_PLUS("mid_plus"), + + @SerializedName("mid_plus_ethanol") + MID_PLUS_ETHANOL("mid_plus_ethanol"), + + @SerializedName("miscellaneous_aviation_products_services") + MISCELLANEOUS_AVIATION_PRODUCTS_SERVICES("miscellaneous_aviation_products_services"), + + @SerializedName("miscellaneous_fuel") + MISCELLANEOUS_FUEL("miscellaneous_fuel"), + + @SerializedName("miscellaneous_marine_products_services") + MISCELLANEOUS_MARINE_PRODUCTS_SERVICES("miscellaneous_marine_products_services"), + + @SerializedName("miscellaneous_vehicle_products_services") + MISCELLANEOUS_VEHICLE_PRODUCTS_SERVICES("miscellaneous_vehicle_products_services"), + + @SerializedName("packaged_beverage") + PACKAGED_BEVERAGE("packaged_beverage"), + + @SerializedName("premium_diesel") + PREMIUM_DIESEL("premium_diesel"), + + @SerializedName("premium_super") + PREMIUM_SUPER("premium_super"), + + @SerializedName("premium_super_ethanol") + PREMIUM_SUPER_ETHANOL("premium_super_ethanol"), + + @SerializedName("preventative_maintenance") + PREVENTATIVE_MAINTENANCE("preventative_maintenance"), + + @SerializedName("regular") + REGULAR("regular"), + + @SerializedName("regular_diesel") + REGULAR_DIESEL("regular_diesel"), + + @SerializedName("regular_ethanol") + REGULAR_ETHANOL("regular_ethanol"), + + @SerializedName("repairs") + REPAIRS("repairs"), + + @SerializedName("self_service_car_wash") + SELF_SERVICE_CAR_WASH("self_service_car_wash"), + + @SerializedName("shower") + SHOWER("shower"), + + @SerializedName("store_service") + STORE_SERVICE("store_service"), + + @SerializedName("tobacco") + TOBACCO("tobacco"), + + @SerializedName("vehicle_accessories") + VEHICLE_ACCESSORIES("vehicle_accessories"), + + @SerializedName("vehicle_parking") + VEHICLE_PARKING("vehicle_parking"), + + @SerializedName("vehicle_parts") + VEHICLE_PARTS("vehicle_parts"), + + @SerializedName("wash_out") + WASH_OUT("wash_out"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ProductType(String value) { + this.value = value; + } + } + + public enum ServiceType implements ApiRequestParams.EnumParam { + @SerializedName("full_service") + FULL_SERVICE("full_service"), + + @SerializedName("high_speed_diesel") + HIGH_SPEED_DIESEL("high_speed_diesel"), + + @SerializedName("non_fuel_only") + NON_FUEL_ONLY("non_fuel_only"), + + @SerializedName("self_service") + SELF_SERVICE("self_service"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ServiceType(String value) { + this.value = value; + } + } } } diff --git a/src/main/java/com/stripe/param/PaymentIntentIncrementAuthorizationParams.java b/src/main/java/com/stripe/param/PaymentIntentIncrementAuthorizationParams.java index a6f744593cb..a9cd1de60a9 100644 --- a/src/main/java/com/stripe/param/PaymentIntentIncrementAuthorizationParams.java +++ b/src/main/java/com/stripe/param/PaymentIntentIncrementAuthorizationParams.java @@ -641,6 +641,13 @@ public static class LineItem { @SerializedName("quantity") Long quantity; + /** + * The number of decimal places implied in the quantity. For example, if quantity is 10000 and + * quantity_precision is 2, the actual quantity is 100.00. Defaults to 0 if not provided. + */ + @SerializedName("quantity_precision") + Long quantityPrecision; + /** Contains information about the tax on the item. */ @SerializedName("tax") Tax tax; @@ -664,6 +671,7 @@ private LineItem( String productCode, String productName, Long quantity, + Long quantityPrecision, Tax tax, Long unitCost, String unitOfMeasure) { @@ -673,6 +681,7 @@ private LineItem( this.productCode = productCode; this.productName = productName; this.quantity = quantity; + this.quantityPrecision = quantityPrecision; this.tax = tax; this.unitCost = unitCost; this.unitOfMeasure = unitOfMeasure; @@ -695,6 +704,8 @@ public static class Builder { private Long quantity; + private Long quantityPrecision; + private Tax tax; private Long unitCost; @@ -710,6 +721,7 @@ public PaymentIntentIncrementAuthorizationParams.AmountDetails.LineItem build() this.productCode, this.productName, this.quantity, + this.quantityPrecision, this.tax, this.unitCost, this.unitOfMeasure); @@ -796,6 +808,16 @@ public Builder setQuantity(Long quantity) { return this; } + /** + * The number of decimal places implied in the quantity. For example, if quantity is 10000 + * and quantity_precision is 2, the actual quantity is 100.00. Defaults to 0 if not + * provided. + */ + public Builder setQuantityPrecision(Long quantityPrecision) { + this.quantityPrecision = quantityPrecision; + return this; + } + /** Contains information about the tax on the item. */ public Builder setTax( PaymentIntentIncrementAuthorizationParams.AmountDetails.LineItem.Tax tax) { @@ -997,9 +1019,14 @@ public static class Card { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private Card(String commodityCode, Map extraParams) { + /** Fleet data for this line item. */ + @SerializedName("fleet_data") + FleetData fleetData; + + private Card(String commodityCode, Map extraParams, FleetData fleetData) { this.commodityCode = commodityCode; this.extraParams = extraParams; + this.fleetData = fleetData; } public static Builder builder() { @@ -1011,12 +1038,14 @@ public static class Builder { private Map extraParams; + private FleetData fleetData; + /** Finalize and obtain parameter instance from this builder. */ public PaymentIntentIncrementAuthorizationParams.AmountDetails.LineItem .PaymentMethodOptions.Card build() { return new PaymentIntentIncrementAuthorizationParams.AmountDetails.LineItem - .PaymentMethodOptions.Card(this.commodityCode, this.extraParams); + .PaymentMethodOptions.Card(this.commodityCode, this.extraParams, this.fleetData); } /** @@ -1057,6 +1086,268 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } + + /** Fleet data for this line item. */ + public Builder setFleetData( + PaymentIntentIncrementAuthorizationParams.AmountDetails.LineItem + .PaymentMethodOptions.Card.FleetData + fleetData) { + this.fleetData = fleetData; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class FleetData { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Required. The type of product being purchased at this line item. */ + @SerializedName("product_type") + ProductType productType; + + /** The type of service received at the acceptor location. */ + @SerializedName("service_type") + ServiceType serviceType; + + private FleetData( + Map extraParams, ProductType productType, ServiceType serviceType) { + this.extraParams = extraParams; + this.productType = productType; + this.serviceType = serviceType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private ProductType productType; + + private ServiceType serviceType; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentIncrementAuthorizationParams.AmountDetails.LineItem + .PaymentMethodOptions.Card.FleetData + build() { + return new PaymentIntentIncrementAuthorizationParams.AmountDetails.LineItem + .PaymentMethodOptions.Card.FleetData( + this.extraParams, this.productType, this.serviceType); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentIncrementAuthorizationParams.AmountDetails.LineItem.PaymentMethodOptions.Card.FleetData#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentIncrementAuthorizationParams.AmountDetails.LineItem.PaymentMethodOptions.Card.FleetData#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. The type of product being purchased at this line item. + */ + public Builder setProductType( + PaymentIntentIncrementAuthorizationParams.AmountDetails.LineItem + .PaymentMethodOptions.Card.FleetData.ProductType + productType) { + this.productType = productType; + return this; + } + + /** The type of service received at the acceptor location. */ + public Builder setServiceType( + PaymentIntentIncrementAuthorizationParams.AmountDetails.LineItem + .PaymentMethodOptions.Card.FleetData.ServiceType + serviceType) { + this.serviceType = serviceType; + return this; + } + } + + public enum ProductType implements ApiRequestParams.EnumParam { + @SerializedName("air_conditioning_service") + AIR_CONDITIONING_SERVICE("air_conditioning_service"), + + @SerializedName("alcohol") + ALCOHOL("alcohol"), + + @SerializedName("aviation_fuel_premium") + AVIATION_FUEL_PREMIUM("aviation_fuel_premium"), + + @SerializedName("aviation_fuel_regular") + AVIATION_FUEL_REGULAR("aviation_fuel_regular"), + + @SerializedName("car_care_detailing") + CAR_CARE_DETAILING("car_care_detailing"), + + @SerializedName("compressed_natural_gas") + COMPRESSED_NATURAL_GAS("compressed_natural_gas"), + + @SerializedName("deli") + DELI("deli"), + + @SerializedName("food_service") + FOOD_SERVICE("food_service"), + + @SerializedName("green_gasoline_mid_plus") + GREEN_GASOLINE_MID_PLUS("green_gasoline_mid_plus"), + + @SerializedName("green_gasoline_premium_super") + GREEN_GASOLINE_PREMIUM_SUPER("green_gasoline_premium_super"), + + @SerializedName("green_gasoline_regular") + GREEN_GASOLINE_REGULAR("green_gasoline_regular"), + + @SerializedName("grocery") + GROCERY("grocery"), + + @SerializedName("liquid_natural_gas") + LIQUID_NATURAL_GAS("liquid_natural_gas"), + + @SerializedName("liquid_propane_gas") + LIQUID_PROPANE_GAS("liquid_propane_gas"), + + @SerializedName("lodging") + LODGING("lodging"), + + @SerializedName("marine_diesel") + MARINE_DIESEL("marine_diesel"), + + @SerializedName("marine_fuel") + MARINE_FUEL("marine_fuel"), + + @SerializedName("merchandise") + MERCHANDISE("merchandise"), + + @SerializedName("mid_plus") + MID_PLUS("mid_plus"), + + @SerializedName("mid_plus_ethanol") + MID_PLUS_ETHANOL("mid_plus_ethanol"), + + @SerializedName("miscellaneous_aviation_products_services") + MISCELLANEOUS_AVIATION_PRODUCTS_SERVICES("miscellaneous_aviation_products_services"), + + @SerializedName("miscellaneous_fuel") + MISCELLANEOUS_FUEL("miscellaneous_fuel"), + + @SerializedName("miscellaneous_marine_products_services") + MISCELLANEOUS_MARINE_PRODUCTS_SERVICES("miscellaneous_marine_products_services"), + + @SerializedName("miscellaneous_vehicle_products_services") + MISCELLANEOUS_VEHICLE_PRODUCTS_SERVICES("miscellaneous_vehicle_products_services"), + + @SerializedName("packaged_beverage") + PACKAGED_BEVERAGE("packaged_beverage"), + + @SerializedName("premium_diesel") + PREMIUM_DIESEL("premium_diesel"), + + @SerializedName("premium_super") + PREMIUM_SUPER("premium_super"), + + @SerializedName("premium_super_ethanol") + PREMIUM_SUPER_ETHANOL("premium_super_ethanol"), + + @SerializedName("preventative_maintenance") + PREVENTATIVE_MAINTENANCE("preventative_maintenance"), + + @SerializedName("regular") + REGULAR("regular"), + + @SerializedName("regular_diesel") + REGULAR_DIESEL("regular_diesel"), + + @SerializedName("regular_ethanol") + REGULAR_ETHANOL("regular_ethanol"), + + @SerializedName("repairs") + REPAIRS("repairs"), + + @SerializedName("self_service_car_wash") + SELF_SERVICE_CAR_WASH("self_service_car_wash"), + + @SerializedName("shower") + SHOWER("shower"), + + @SerializedName("store_service") + STORE_SERVICE("store_service"), + + @SerializedName("tobacco") + TOBACCO("tobacco"), + + @SerializedName("vehicle_accessories") + VEHICLE_ACCESSORIES("vehicle_accessories"), + + @SerializedName("vehicle_parking") + VEHICLE_PARKING("vehicle_parking"), + + @SerializedName("vehicle_parts") + VEHICLE_PARTS("vehicle_parts"), + + @SerializedName("wash_out") + WASH_OUT("wash_out"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ProductType(String value) { + this.value = value; + } + } + + public enum ServiceType implements ApiRequestParams.EnumParam { + @SerializedName("full_service") + FULL_SERVICE("full_service"), + + @SerializedName("high_speed_diesel") + HIGH_SPEED_DIESEL("high_speed_diesel"), + + @SerializedName("non_fuel_only") + NON_FUEL_ONLY("non_fuel_only"), + + @SerializedName("self_service") + SELF_SERVICE("self_service"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ServiceType(String value) { + this.value = value; + } + } } } diff --git a/src/main/java/com/stripe/param/PaymentIntentUpdateParams.java b/src/main/java/com/stripe/param/PaymentIntentUpdateParams.java index 01150119f23..9db3869243e 100644 --- a/src/main/java/com/stripe/param/PaymentIntentUpdateParams.java +++ b/src/main/java/com/stripe/param/PaymentIntentUpdateParams.java @@ -1399,6 +1399,13 @@ public static class LineItem { @SerializedName("quantity") Long quantity; + /** + * The number of decimal places implied in the quantity. For example, if quantity is 10000 and + * quantity_precision is 2, the actual quantity is 100.00. Defaults to 0 if not provided. + */ + @SerializedName("quantity_precision") + Long quantityPrecision; + /** Contains information about the tax on the item. */ @SerializedName("tax") Tax tax; @@ -1422,6 +1429,7 @@ private LineItem( Object productCode, Object productName, Long quantity, + Long quantityPrecision, Tax tax, Long unitCost, Object unitOfMeasure) { @@ -1431,6 +1439,7 @@ private LineItem( this.productCode = productCode; this.productName = productName; this.quantity = quantity; + this.quantityPrecision = quantityPrecision; this.tax = tax; this.unitCost = unitCost; this.unitOfMeasure = unitOfMeasure; @@ -1453,6 +1462,8 @@ public static class Builder { private Long quantity; + private Long quantityPrecision; + private Tax tax; private Long unitCost; @@ -1468,6 +1479,7 @@ public PaymentIntentUpdateParams.AmountDetails.LineItem build() { this.productCode, this.productName, this.quantity, + this.quantityPrecision, this.tax, this.unitCost, this.unitOfMeasure); @@ -1573,6 +1585,16 @@ public Builder setQuantity(Long quantity) { return this; } + /** + * The number of decimal places implied in the quantity. For example, if quantity is 10000 + * and quantity_precision is 2, the actual quantity is 100.00. Defaults to 0 if not + * provided. + */ + public Builder setQuantityPrecision(Long quantityPrecision) { + this.quantityPrecision = quantityPrecision; + return this; + } + /** Contains information about the tax on the item. */ public Builder setTax(PaymentIntentUpdateParams.AmountDetails.LineItem.Tax tax) { this.tax = tax; @@ -1769,9 +1791,14 @@ public static class Card { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private Card(Object commodityCode, Map extraParams) { + /** Fleet data for this line item. */ + @SerializedName("fleet_data") + FleetData fleetData; + + private Card(Object commodityCode, Map extraParams, FleetData fleetData) { this.commodityCode = commodityCode; this.extraParams = extraParams; + this.fleetData = fleetData; } public static Builder builder() { @@ -1783,11 +1810,13 @@ public static class Builder { private Map extraParams; + private FleetData fleetData; + /** Finalize and obtain parameter instance from this builder. */ public PaymentIntentUpdateParams.AmountDetails.LineItem.PaymentMethodOptions.Card build() { return new PaymentIntentUpdateParams.AmountDetails.LineItem.PaymentMethodOptions.Card( - this.commodityCode, this.extraParams); + this.commodityCode, this.extraParams, this.fleetData); } /** @@ -1837,6 +1866,266 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } + + /** Fleet data for this line item. */ + public Builder setFleetData( + PaymentIntentUpdateParams.AmountDetails.LineItem.PaymentMethodOptions.Card.FleetData + fleetData) { + this.fleetData = fleetData; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class FleetData { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Required. The type of product being purchased at this line item. */ + @SerializedName("product_type") + ProductType productType; + + /** The type of service received at the acceptor location. */ + @SerializedName("service_type") + ServiceType serviceType; + + private FleetData( + Map extraParams, ProductType productType, ServiceType serviceType) { + this.extraParams = extraParams; + this.productType = productType; + this.serviceType = serviceType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private ProductType productType; + + private ServiceType serviceType; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.AmountDetails.LineItem.PaymentMethodOptions.Card + .FleetData + build() { + return new PaymentIntentUpdateParams.AmountDetails.LineItem.PaymentMethodOptions + .Card.FleetData(this.extraParams, this.productType, this.serviceType); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.AmountDetails.LineItem.PaymentMethodOptions.Card.FleetData#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.AmountDetails.LineItem.PaymentMethodOptions.Card.FleetData#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. The type of product being purchased at this line item. + */ + public Builder setProductType( + PaymentIntentUpdateParams.AmountDetails.LineItem.PaymentMethodOptions.Card + .FleetData.ProductType + productType) { + this.productType = productType; + return this; + } + + /** The type of service received at the acceptor location. */ + public Builder setServiceType( + PaymentIntentUpdateParams.AmountDetails.LineItem.PaymentMethodOptions.Card + .FleetData.ServiceType + serviceType) { + this.serviceType = serviceType; + return this; + } + } + + public enum ProductType implements ApiRequestParams.EnumParam { + @SerializedName("air_conditioning_service") + AIR_CONDITIONING_SERVICE("air_conditioning_service"), + + @SerializedName("alcohol") + ALCOHOL("alcohol"), + + @SerializedName("aviation_fuel_premium") + AVIATION_FUEL_PREMIUM("aviation_fuel_premium"), + + @SerializedName("aviation_fuel_regular") + AVIATION_FUEL_REGULAR("aviation_fuel_regular"), + + @SerializedName("car_care_detailing") + CAR_CARE_DETAILING("car_care_detailing"), + + @SerializedName("compressed_natural_gas") + COMPRESSED_NATURAL_GAS("compressed_natural_gas"), + + @SerializedName("deli") + DELI("deli"), + + @SerializedName("food_service") + FOOD_SERVICE("food_service"), + + @SerializedName("green_gasoline_mid_plus") + GREEN_GASOLINE_MID_PLUS("green_gasoline_mid_plus"), + + @SerializedName("green_gasoline_premium_super") + GREEN_GASOLINE_PREMIUM_SUPER("green_gasoline_premium_super"), + + @SerializedName("green_gasoline_regular") + GREEN_GASOLINE_REGULAR("green_gasoline_regular"), + + @SerializedName("grocery") + GROCERY("grocery"), + + @SerializedName("liquid_natural_gas") + LIQUID_NATURAL_GAS("liquid_natural_gas"), + + @SerializedName("liquid_propane_gas") + LIQUID_PROPANE_GAS("liquid_propane_gas"), + + @SerializedName("lodging") + LODGING("lodging"), + + @SerializedName("marine_diesel") + MARINE_DIESEL("marine_diesel"), + + @SerializedName("marine_fuel") + MARINE_FUEL("marine_fuel"), + + @SerializedName("merchandise") + MERCHANDISE("merchandise"), + + @SerializedName("mid_plus") + MID_PLUS("mid_plus"), + + @SerializedName("mid_plus_ethanol") + MID_PLUS_ETHANOL("mid_plus_ethanol"), + + @SerializedName("miscellaneous_aviation_products_services") + MISCELLANEOUS_AVIATION_PRODUCTS_SERVICES("miscellaneous_aviation_products_services"), + + @SerializedName("miscellaneous_fuel") + MISCELLANEOUS_FUEL("miscellaneous_fuel"), + + @SerializedName("miscellaneous_marine_products_services") + MISCELLANEOUS_MARINE_PRODUCTS_SERVICES("miscellaneous_marine_products_services"), + + @SerializedName("miscellaneous_vehicle_products_services") + MISCELLANEOUS_VEHICLE_PRODUCTS_SERVICES("miscellaneous_vehicle_products_services"), + + @SerializedName("packaged_beverage") + PACKAGED_BEVERAGE("packaged_beverage"), + + @SerializedName("premium_diesel") + PREMIUM_DIESEL("premium_diesel"), + + @SerializedName("premium_super") + PREMIUM_SUPER("premium_super"), + + @SerializedName("premium_super_ethanol") + PREMIUM_SUPER_ETHANOL("premium_super_ethanol"), + + @SerializedName("preventative_maintenance") + PREVENTATIVE_MAINTENANCE("preventative_maintenance"), + + @SerializedName("regular") + REGULAR("regular"), + + @SerializedName("regular_diesel") + REGULAR_DIESEL("regular_diesel"), + + @SerializedName("regular_ethanol") + REGULAR_ETHANOL("regular_ethanol"), + + @SerializedName("repairs") + REPAIRS("repairs"), + + @SerializedName("self_service_car_wash") + SELF_SERVICE_CAR_WASH("self_service_car_wash"), + + @SerializedName("shower") + SHOWER("shower"), + + @SerializedName("store_service") + STORE_SERVICE("store_service"), + + @SerializedName("tobacco") + TOBACCO("tobacco"), + + @SerializedName("vehicle_accessories") + VEHICLE_ACCESSORIES("vehicle_accessories"), + + @SerializedName("vehicle_parking") + VEHICLE_PARKING("vehicle_parking"), + + @SerializedName("vehicle_parts") + VEHICLE_PARTS("vehicle_parts"), + + @SerializedName("wash_out") + WASH_OUT("wash_out"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ProductType(String value) { + this.value = value; + } + } + + public enum ServiceType implements ApiRequestParams.EnumParam { + @SerializedName("full_service") + FULL_SERVICE("full_service"), + + @SerializedName("high_speed_diesel") + HIGH_SPEED_DIESEL("high_speed_diesel"), + + @SerializedName("non_fuel_only") + NON_FUEL_ONLY("non_fuel_only"), + + @SerializedName("self_service") + SELF_SERVICE("self_service"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ServiceType(String value) { + this.value = value; + } + } } } @@ -3224,6 +3513,10 @@ public static class PaymentDetails { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; + /** Fleet data for this PaymentIntent. */ + @SerializedName("fleet_data") + Object fleetData; + /** Flight reservation details for this PaymentIntent. */ @SerializedName("flight") Flight flight; @@ -3266,6 +3559,7 @@ private PaymentDetails( Object customerReference, EventDetails eventDetails, Map extraParams, + Object fleetData, Flight flight, Object flightData, Lodging lodging, @@ -3279,6 +3573,7 @@ private PaymentDetails( this.customerReference = customerReference; this.eventDetails = eventDetails; this.extraParams = extraParams; + this.fleetData = fleetData; this.flight = flight; this.flightData = flightData; this.lodging = lodging; @@ -3305,6 +3600,8 @@ public static class Builder { private Map extraParams; + private Object fleetData; + private Flight flight; private Object flightData; @@ -3328,6 +3625,7 @@ public PaymentIntentUpdateParams.PaymentDetails build() { this.customerReference, this.eventDetails, this.extraParams, + this.fleetData, this.flight, this.flightData, this.lodging, @@ -3452,6 +3750,49 @@ public Builder putAllExtraParam(Map map) { return this; } + /** + * Add an element to `fleetData` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails#fleetData} for the field documentation. + */ + @SuppressWarnings("unchecked") + public Builder addFleetData(PaymentIntentUpdateParams.PaymentDetails.FleetData element) { + if (this.fleetData == null || this.fleetData instanceof EmptyParam) { + this.fleetData = new ArrayList(); + } + ((List) this.fleetData).add(element); + return this; + } + + /** + * Add all elements to `fleetData` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails#fleetData} for the field documentation. + */ + @SuppressWarnings("unchecked") + public Builder addAllFleetData( + List elements) { + if (this.fleetData == null || this.fleetData instanceof EmptyParam) { + this.fleetData = new ArrayList(); + } + ((List) this.fleetData) + .addAll(elements); + return this; + } + + /** Fleet data for this PaymentIntent. */ + public Builder setFleetData(EmptyParam fleetData) { + this.fleetData = fleetData; + return this; + } + + /** Fleet data for this PaymentIntent. */ + public Builder setFleetData( + List fleetData) { + this.fleetData = fleetData; + return this; + } + /** Flight reservation details for this PaymentIntent. */ public Builder setFlight(PaymentIntentUpdateParams.PaymentDetails.Flight flight) { this.flight = flight; @@ -8664,29 +9005,7 @@ public enum Mode implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class Flight { - /** Affiliate details for this purchase. */ - @SerializedName("affiliate") - Affiliate affiliate; - - /** - * The agency number (i.e. International Air Transport Association (IATA) agency number) of - * the travel agency that made the booking. - */ - @SerializedName("agency_number") - Object agencyNumber; - - /** - * The International Air Transport Association (IATA) carrier code of the carrier that issued - * the ticket. - */ - @SerializedName("carrier") - Object carrier; - - /** Delivery details for this purchase. */ - @SerializedName("delivery") - Delivery delivery; - + public static class FleetData { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -8696,41 +9015,27 @@ public static class Flight { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** The name of the person or entity on the reservation. */ - @SerializedName("passenger_name") - Object passengerName; - - /** The details of the passengers in the travel reservation. */ - @SerializedName("passengers") - List passengers; + /** Primary fuel fields for the transaction. */ + @SerializedName("primary_fuel_fields") + PrimaryFuelFields primaryFuelFields; - /** Required. The individual flight segments associated with the trip. */ - @SerializedName("segments") - List segments; + /** Station and acceptor location details. */ + @SerializedName("station") + Station station; - /** The ticket number associated with the travel reservation. */ - @SerializedName("ticket_number") - Object ticketNumber; + /** VAT and Invoice on Behalf (IOB) details. */ + @SerializedName("vat") + Vat vat; - private Flight( - Affiliate affiliate, - Object agencyNumber, - Object carrier, - Delivery delivery, + private FleetData( Map extraParams, - Object passengerName, - List passengers, - List segments, - Object ticketNumber) { - this.affiliate = affiliate; - this.agencyNumber = agencyNumber; - this.carrier = carrier; - this.delivery = delivery; + PrimaryFuelFields primaryFuelFields, + Station station, + Vat vat) { this.extraParams = extraParams; - this.passengerName = passengerName; - this.passengers = passengers; - this.segments = segments; - this.ticketNumber = ticketNumber; + this.primaryFuelFields = primaryFuelFields; + this.station = station; + this.vat = vat; } public static Builder builder() { @@ -8738,93 +9043,25 @@ public static Builder builder() { } public static class Builder { - private Affiliate affiliate; - - private Object agencyNumber; - - private Object carrier; - - private Delivery delivery; - private Map extraParams; - private Object passengerName; - - private List passengers; + private PrimaryFuelFields primaryFuelFields; - private List segments; + private Station station; - private Object ticketNumber; + private Vat vat; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.Flight build() { - return new PaymentIntentUpdateParams.PaymentDetails.Flight( - this.affiliate, - this.agencyNumber, - this.carrier, - this.delivery, - this.extraParams, - this.passengerName, - this.passengers, - this.segments, - this.ticketNumber); - } - - /** Affiliate details for this purchase. */ - public Builder setAffiliate( - PaymentIntentUpdateParams.PaymentDetails.Flight.Affiliate affiliate) { - this.affiliate = affiliate; - return this; + public PaymentIntentUpdateParams.PaymentDetails.FleetData build() { + return new PaymentIntentUpdateParams.PaymentDetails.FleetData( + this.extraParams, this.primaryFuelFields, this.station, this.vat); } /** - * The agency number (i.e. International Air Transport Association (IATA) agency number) of - * the travel agency that made the booking. - */ - public Builder setAgencyNumber(String agencyNumber) { - this.agencyNumber = agencyNumber; - return this; - } - - /** - * The agency number (i.e. International Air Transport Association (IATA) agency number) of - * the travel agency that made the booking. - */ - public Builder setAgencyNumber(EmptyParam agencyNumber) { - this.agencyNumber = agencyNumber; - return this; - } - - /** - * The International Air Transport Association (IATA) carrier code of the carrier that - * issued the ticket. - */ - public Builder setCarrier(String carrier) { - this.carrier = carrier; - return this; - } - - /** - * The International Air Transport Association (IATA) carrier code of the carrier that - * issued the ticket. - */ - public Builder setCarrier(EmptyParam carrier) { - this.carrier = carrier; - return this; - } - - /** Delivery details for this purchase. */ - public Builder setDelivery( - PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery delivery) { - this.delivery = delivery; - return this; - } - - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight#extraParams} for the - * field documentation. + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.FleetData#extraParams} for the + * field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -8837,7 +9074,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight#extraParams} for the + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.FleetData#extraParams} for the * field documentation. */ public Builder putAllExtraParam(Map map) { @@ -8848,89 +9085,35 @@ public Builder putAllExtraParam(Map map) { return this; } - /** The name of the person or entity on the reservation. */ - public Builder setPassengerName(String passengerName) { - this.passengerName = passengerName; - return this; - } - - /** The name of the person or entity on the reservation. */ - public Builder setPassengerName(EmptyParam passengerName) { - this.passengerName = passengerName; - return this; - } - - /** - * Add an element to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.Flight#passengers} for the field documentation. - */ - public Builder addPassenger( - PaymentIntentUpdateParams.PaymentDetails.Flight.Passenger element) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.add(element); - return this; - } - - /** - * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.Flight#passengers} for the field documentation. - */ - public Builder addAllPassenger( - List elements) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); - } - this.passengers.addAll(elements); - return this; - } - - /** - * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.Flight#segments} for the field documentation. - */ - public Builder addSegment(PaymentIntentUpdateParams.PaymentDetails.Flight.Segment element) { - if (this.segments == null) { - this.segments = new ArrayList<>(); - } - this.segments.add(element); - return this; - } - - /** - * Add all elements to `segments` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.Flight#segments} for the field documentation. - */ - public Builder addAllSegment( - List elements) { - if (this.segments == null) { - this.segments = new ArrayList<>(); - } - this.segments.addAll(elements); + /** Primary fuel fields for the transaction. */ + public Builder setPrimaryFuelFields( + PaymentIntentUpdateParams.PaymentDetails.FleetData.PrimaryFuelFields + primaryFuelFields) { + this.primaryFuelFields = primaryFuelFields; return this; } - /** The ticket number associated with the travel reservation. */ - public Builder setTicketNumber(String ticketNumber) { - this.ticketNumber = ticketNumber; + /** Station and acceptor location details. */ + public Builder setStation( + PaymentIntentUpdateParams.PaymentDetails.FleetData.Station station) { + this.station = station; return this; } - /** The ticket number associated with the travel reservation. */ - public Builder setTicketNumber(EmptyParam ticketNumber) { - this.ticketNumber = ticketNumber; + /** VAT and Invoice on Behalf (IOB) details. */ + public Builder setVat(PaymentIntentUpdateParams.PaymentDetails.FleetData.Vat vat) { + this.vat = vat; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Affiliate { + public static class PrimaryFuelFields { + /** The fuel brand. */ + @SerializedName("brand") + Brand brand; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -8941,13 +9124,9 @@ public static class Affiliate { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Required. The name of the affiliate that originated the purchase. */ - @SerializedName("name") - Object name; - - private Affiliate(Map extraParams, Object name) { + private PrimaryFuelFields(Brand brand, Map extraParams) { + this.brand = brand; this.extraParams = extraParams; - this.name = name; } public static Builder builder() { @@ -8955,21 +9134,29 @@ public static Builder builder() { } public static class Builder { - private Map extraParams; + private Brand brand; - private Object name; + private Map extraParams; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.Flight.Affiliate build() { - return new PaymentIntentUpdateParams.PaymentDetails.Flight.Affiliate( - this.extraParams, this.name); + public PaymentIntentUpdateParams.PaymentDetails.FleetData.PrimaryFuelFields build() { + return new PaymentIntentUpdateParams.PaymentDetails.FleetData.PrimaryFuelFields( + this.brand, this.extraParams); + } + + /** The fuel brand. */ + public Builder setBrand( + PaymentIntentUpdateParams.PaymentDetails.FleetData.PrimaryFuelFields.Brand brand) { + this.brand = brand; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight.Affiliate#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FleetData.PrimaryFuelFields#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -8982,8 +9169,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight.Affiliate#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FleetData.PrimaryFuelFields#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -8992,245 +9180,409 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } + } - /** Required. The name of the affiliate that originated the purchase. */ - public Builder setName(String name) { - this.name = name; - return this; - } + public enum Brand implements ApiRequestParams.EnumParam { + @SerializedName("aafes") + AAFES("aafes"), - /** Required. The name of the affiliate that originated the purchase. */ - public Builder setName(EmptyParam name) { - this.name = name; - return this; - } - } - } + @SerializedName("amerada_hess") + AMERADA_HESS("amerada_hess"), - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Delivery { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + @SerializedName("amoco_canada") + AMOCO_CANADA("amoco_canada"), - /** The delivery method for the payment. */ - @SerializedName("mode") - Mode mode; + @SerializedName("amoco_petroleum_products") + AMOCO_PETROLEUM_PRODUCTS("amoco_petroleum_products"), - /** Details of the recipient. */ - @SerializedName("recipient") - Recipient recipient; + @SerializedName("arco_products") + ARCO_PRODUCTS("arco_products"), - private Delivery(Map extraParams, Mode mode, Recipient recipient) { - this.extraParams = extraParams; - this.mode = mode; - this.recipient = recipient; - } + @SerializedName("asda") + ASDA("asda"), - public static Builder builder() { - return new Builder(); - } + @SerializedName("ashland_oil") + ASHLAND_OIL("ashland_oil"), - public static class Builder { - private Map extraParams; + @SerializedName("bfl") + BFL("bfl"), - private Mode mode; + @SerializedName("bp_mobil") + BP_MOBIL("bp_mobil"), - private Recipient recipient; + @SerializedName("bp_oil") + BP_OIL("bp_oil"), - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery build() { - return new PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery( - this.extraParams, this.mode, this.recipient); - } + @SerializedName("burrnah_major") + BURRNAH_MAJOR("burrnah_major"), - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + @SerializedName("butler_arndale") + BUTLER_ARNDALE("butler_arndale"), - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + @SerializedName("canadian_tire") + CANADIAN_TIRE("canadian_tire"), - /** The delivery method for the payment. */ - public Builder setMode( - PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery.Mode mode) { - this.mode = mode; - return this; - } + @SerializedName("canadian_turbo") + CANADIAN_TURBO("canadian_turbo"), - /** Details of the recipient. */ - public Builder setRecipient( - PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery.Recipient recipient) { - this.recipient = recipient; - return this; - } - } + @SerializedName("caseys_general_store") + CASEYS_GENERAL_STORE("caseys_general_store"), - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Recipient { - /** The email of the recipient the ticket is delivered to. */ - @SerializedName("email") - Object email; + @SerializedName("cenex") + CENEX("cenex"), - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + @SerializedName("chevron_canada") + CHEVRON_CANADA("chevron_canada"), - /** The name of the recipient the ticket is delivered to. */ - @SerializedName("name") - Object name; + @SerializedName("chevron_usa") + CHEVRON_USA("chevron_usa"), - /** The phone number of the recipient the ticket is delivered to. */ - @SerializedName("phone") - Object phone; + @SerializedName("circle_k_stores") + CIRCLE_K_STORES("circle_k_stores"), - private Recipient( - Object email, Map extraParams, Object name, Object phone) { - this.email = email; - this.extraParams = extraParams; - this.name = name; - this.phone = phone; - } + @SerializedName("citgo_petroleum") + CITGO_PETROLEUM("citgo_petroleum"), - public static Builder builder() { - return new Builder(); - } + @SerializedName("clark_brands") + CLARK_BRANDS("clark_brands"), - public static class Builder { - private Object email; + @SerializedName("conoco_canada") + CONOCO_CANADA("conoco_canada"), - private Map extraParams; + @SerializedName("conoco_inc") + CONOCO_INC("conoco_inc"), - private Object name; + @SerializedName("crown_central_petroleum") + CROWN_CENTRAL_PETROLEUM("crown_central_petroleum"), - private Object phone; + @SerializedName("diamond_shamrock_inc") + DIAMOND_SHAMROCK_INC("diamond_shamrock_inc"), - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery.Recipient build() { - return new PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery.Recipient( - this.email, this.extraParams, this.name, this.phone); - } + @SerializedName("discount_tire") + DISCOUNT_TIRE("discount_tire"), - /** The email of the recipient the ticket is delivered to. */ - public Builder setEmail(String email) { - this.email = email; - return this; - } + @SerializedName("domo_gas") + DOMO_GAS("domo_gas"), - /** The email of the recipient the ticket is delivered to. */ - public Builder setEmail(EmptyParam email) { - this.email = email; - return this; - } + @SerializedName("elf") + ELF("elf"), - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + @SerializedName("erickson_oil") + ERICKSON_OIL("erickson_oil"), - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + @SerializedName("esso") + ESSO("esso"), - /** The name of the recipient the ticket is delivered to. */ - public Builder setName(String name) { - this.name = name; - return this; - } + @SerializedName("esso_canada") + ESSO_CANADA("esso_canada"), - /** The name of the recipient the ticket is delivered to. */ - public Builder setName(EmptyParam name) { - this.name = name; - return this; - } + @SerializedName("exxon") + EXXON("exxon"), - /** The phone number of the recipient the ticket is delivered to. */ - public Builder setPhone(String phone) { - this.phone = phone; - return this; - } + @SerializedName("exxonmobil") + EXXONMOBIL("exxonmobil"), - /** The phone number of the recipient the ticket is delivered to. */ - public Builder setPhone(EmptyParam phone) { - this.phone = phone; - return this; - } - } - } + @SerializedName("family_express") + FAMILY_EXPRESS("family_express"), - public enum Mode implements ApiRequestParams.EnumParam { - @SerializedName("email") - EMAIL("email"), + @SerializedName("fas_gas_oil") + FAS_GAS_OIL("fas_gas_oil"), - @SerializedName("phone") - PHONE("phone"), + @SerializedName("federated_coop_sonic") + FEDERATED_COOP_SONIC("federated_coop_sonic"), - @SerializedName("pickup") - PICKUP("pickup"), + @SerializedName("fina") + FINA("fina"), - @SerializedName("post") - POST("post"); + @SerializedName("fina_inc") + FINA_INC("fina_inc"), + + @SerializedName("fkg_oil") + FKG_OIL("fkg_oil"), + + @SerializedName("flare") + FLARE("flare"), + + @SerializedName("flying_j_inc") + FLYING_J_INC("flying_j_inc"), + + @SerializedName("gas_america") + GAS_AMERICA("gas_america"), + + @SerializedName("gate_petroleum") + GATE_PETROLEUM("gate_petroleum"), + + @SerializedName("getty_petroleum") + GETTY_PETROLEUM("getty_petroleum"), + + @SerializedName("giant_eagle") + GIANT_EAGLE("giant_eagle"), + + @SerializedName("grow_mark_inc") + GROW_MARK_INC("grow_mark_inc"), + + @SerializedName("gulf") + GULF("gulf"), + + @SerializedName("gulf_canada") + GULF_CANADA("gulf_canada"), + + @SerializedName("gulf_chevron") + GULF_CHEVRON("gulf_chevron"), + + @SerializedName("handy_way_food") + HANDY_WAY_FOOD("handy_way_food"), + + @SerializedName("heron") + HERON("heron"), + + @SerializedName("holiday_stores") + HOLIDAY_STORES("holiday_stores"), + + @SerializedName("home_depot") + HOME_DEPOT("home_depot"), + + @SerializedName("husky") + HUSKY("husky"), + + @SerializedName("hyvees") + HYVEES("hyvees"), + + @SerializedName("irving") + IRVING("irving"), + + @SerializedName("irving_oil") + IRVING_OIL("irving_oil"), + + @SerializedName("j_sainsbury") + J_SAINSBURY("j_sainsbury"), + + @SerializedName("jet_conoco") + JET_CONOCO("jet_conoco"), + + @SerializedName("krogers") + KROGERS("krogers"), + + @SerializedName("kuwait") + KUWAIT("kuwait"), + + @SerializedName("kwik_trip_inc") + KWIK_TRIP_INC("kwik_trip_inc"), + + @SerializedName("lassus") + LASSUS("lassus"), + + @SerializedName("loves_country_stores") + LOVES_COUNTRY_STORES("loves_country_stores"), + + @SerializedName("mapco_express_inc") + MAPCO_EXPRESS_INC("mapco_express_inc"), + + @SerializedName("marathon_oil") + MARATHON_OIL("marathon_oil"), + + @SerializedName("martin_bailey_inc_dba_hucks") + MARTIN_BAILEY_INC_DBA_HUCKS("martin_bailey_inc_dba_hucks"), + + @SerializedName("maxol") + MAXOL("maxol"), + + @SerializedName("meineke") + MEINEKE("meineke"), + + @SerializedName("mfa") + MFA("mfa"), + + @SerializedName("mohawk") + MOHAWK("mohawk"), + + @SerializedName("mr_gas") + MR_GAS("mr_gas"), + + @SerializedName("murco") + MURCO("murco"), + + @SerializedName("murphy_oil_canada") + MURPHY_OIL_CANADA("murphy_oil_canada"), + + @SerializedName("murphy_oil_usa_inc") + MURPHY_OIL_USA_INC("murphy_oil_usa_inc"), + + @SerializedName("nexcom") + NEXCOM("nexcom"), + + @SerializedName("nordstrom_oil") + NORDSTROM_OIL("nordstrom_oil"), + + @SerializedName("olco") + OLCO("olco"), + + @SerializedName("pdq_store") + PDQ_STORE("pdq_store"), + + @SerializedName("pennzoil_products_inc") + PENNZOIL_PRODUCTS_INC("pennzoil_products_inc"), + + @SerializedName("petro") + PETRO("petro"), + + @SerializedName("petro_canada") + PETRO_CANADA("petro_canada"), + + @SerializedName("petro_t") + PETRO_T("petro_t"), + + @SerializedName("phillips") + PHILLIPS("phillips"), + + @SerializedName("pilot") + PILOT("pilot"), + + @SerializedName("pioneer") + PIONEER("pioneer"), + + @SerializedName("pure_oil") + PURE_OIL("pure_oil"), + + @SerializedName("quaker_state") + QUAKER_STATE("quaker_state"), + + @SerializedName("quarles_oil") + QUARLES_OIL("quarles_oil"), + + @SerializedName("quiktrip") + QUIKTRIP("quiktrip"), + + @SerializedName("racetrac_petroleum_inc") + RACETRAC_PETROLEUM_INC("racetrac_petroleum_inc"), + + @SerializedName("raceway_petroleum") + RACEWAY_PETROLEUM("raceway_petroleum"), + + @SerializedName("repsol") + REPSOL("repsol"), + + @SerializedName("rudy") + RUDY("rudy"), + + @SerializedName("safeway") + SAFEWAY("safeway"), + + @SerializedName("seven_eleven") + SEVEN_ELEVEN("seven_eleven"), + + @SerializedName("sheetz") + SHEETZ("sheetz"), + + @SerializedName("shell") + SHELL("shell"), + + @SerializedName("shell_canada") + SHELL_CANADA("shell_canada"), + + @SerializedName("shell_oil") + SHELL_OIL("shell_oil"), + + @SerializedName("sinclair_oil") + SINCLAIR_OIL("sinclair_oil"), + + @SerializedName("southland_oil") + SOUTHLAND_OIL("southland_oil"), + + @SerializedName("spar") + SPAR("spar"), + + @SerializedName("speedway") + SPEEDWAY("speedway"), + + @SerializedName("sun_company_inc") + SUN_COMPANY_INC("sun_company_inc"), + + @SerializedName("suncor_sunoco_canada") + SUNCOR_SUNOCO_CANADA("suncor_sunoco_canada"), + + @SerializedName("tempo") + TEMPO("tempo"), + + @SerializedName("tesco") + TESCO("tesco"), + + @SerializedName("tesoro_alaska") + TESORO_ALASKA("tesoro_alaska"), + + @SerializedName("texaco") + TEXACO("texaco"), + + @SerializedName("the_pantry_inc") + THE_PANTRY_INC("the_pantry_inc"), + + @SerializedName("thornton_oil") + THORNTON_OIL("thornton_oil"), + + @SerializedName("tosco") + TOSCO("tosco"), + + @SerializedName("total") + TOTAL("total"), + + @SerializedName("travel_centers_of_america") + TRAVEL_CENTERS_OF_AMERICA("travel_centers_of_america"), + + @SerializedName("uk") + UK("uk"), + + @SerializedName("ultramar_canada") + ULTRAMAR_CANADA("ultramar_canada"), + + @SerializedName("unbranded_or_unassigned") + UNBRANDED_OR_UNASSIGNED("unbranded_or_unassigned"), + + @SerializedName("unbranded_unassigned") + UNBRANDED_UNASSIGNED("unbranded_unassigned"), + + @SerializedName("union_76") + UNION_76("union_76"), + + @SerializedName("united_dairy_farmer") + UNITED_DAIRY_FARMER("united_dairy_farmer"), + + @SerializedName("united_refining_kwikfill") + UNITED_REFINING_KWIKFILL("united_refining_kwikfill"), + + @SerializedName("us_oil") + US_OIL("us_oil"), + + @SerializedName("usa_petroleum") + USA_PETROLEUM("usa_petroleum"), + + @SerializedName("valvoline") + VALVOLINE("valvoline"), + + @SerializedName("vg") + VG("vg"), + + @SerializedName("w_morrison") + W_MORRISON("w_morrison"), + + @SerializedName("warren_equities") + WARREN_EQUITIES("warren_equities"), + + @SerializedName("wawa") + WAWA("wawa"), + + @SerializedName("western_energetix") + WESTERN_ENERGETIX("western_energetix"), + + @SerializedName("wilco") + WILCO("wilco"), + + @SerializedName("zions") + ZIONS("zions"); @Getter(onMethod_ = {@Override}) private final String value; - Mode(String value) { + Brand(String value) { this.value = value; } } @@ -9238,7 +9590,15 @@ public enum Mode implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class Passenger { + public static class Station { + /** Additional contact information for the station. */ + @SerializedName("additional_contact_info") + Object additionalContactInfo; + + /** The customer service phone number of the station. */ + @SerializedName("customer_service_phone_number") + Object customerServicePhoneNumber; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -9249,15 +9609,37 @@ public static class Passenger { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** - * Required. Full name of the person or entity on the flight reservation. - */ - @SerializedName("name") - Object name; + /** The partner ID code of the station. */ + @SerializedName("partner_id_code") + Object partnerIdCode; - private Passenger(Map extraParams, Object name) { + /** The phone number of the station. */ + @SerializedName("phone_number") + Object phoneNumber; + + /** The physical location of the station. */ + @SerializedName("service_location") + ServiceLocation serviceLocation; + + /** The URL of the station. */ + @SerializedName("url") + Object url; + + private Station( + Object additionalContactInfo, + Object customerServicePhoneNumber, + Map extraParams, + Object partnerIdCode, + Object phoneNumber, + ServiceLocation serviceLocation, + Object url) { + this.additionalContactInfo = additionalContactInfo; + this.customerServicePhoneNumber = customerServicePhoneNumber; this.extraParams = extraParams; - this.name = name; + this.partnerIdCode = partnerIdCode; + this.phoneNumber = phoneNumber; + this.serviceLocation = serviceLocation; + this.url = url; } public static Builder builder() { @@ -9265,20 +9647,60 @@ public static Builder builder() { } public static class Builder { + private Object additionalContactInfo; + + private Object customerServicePhoneNumber; + private Map extraParams; - private Object name; + private Object partnerIdCode; + + private Object phoneNumber; + + private ServiceLocation serviceLocation; + + private Object url; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.Flight.Passenger build() { - return new PaymentIntentUpdateParams.PaymentDetails.Flight.Passenger( - this.extraParams, this.name); + public PaymentIntentUpdateParams.PaymentDetails.FleetData.Station build() { + return new PaymentIntentUpdateParams.PaymentDetails.FleetData.Station( + this.additionalContactInfo, + this.customerServicePhoneNumber, + this.extraParams, + this.partnerIdCode, + this.phoneNumber, + this.serviceLocation, + this.url); + } + + /** Additional contact information for the station. */ + public Builder setAdditionalContactInfo(String additionalContactInfo) { + this.additionalContactInfo = additionalContactInfo; + return this; + } + + /** Additional contact information for the station. */ + public Builder setAdditionalContactInfo(EmptyParam additionalContactInfo) { + this.additionalContactInfo = additionalContactInfo; + return this; + } + + /** The customer service phone number of the station. */ + public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; + } + + /** The customer service phone number of the station. */ + public Builder setCustomerServicePhoneNumber(EmptyParam customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight.Passenger#extraParams} + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.FleetData.Station#extraParams} * for the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -9292,7 +9714,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight.Passenger#extraParams} + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.FleetData.Station#extraParams} * for the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -9303,279 +9725,363 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Required. Full name of the person or entity on the flight reservation. - */ - public Builder setName(String name) { - this.name = name; + /** The partner ID code of the station. */ + public Builder setPartnerIdCode(String partnerIdCode) { + this.partnerIdCode = partnerIdCode; return this; } - /** - * Required. Full name of the person or entity on the flight reservation. - */ - public Builder setName(EmptyParam name) { - this.name = name; + /** The partner ID code of the station. */ + public Builder setPartnerIdCode(EmptyParam partnerIdCode) { + this.partnerIdCode = partnerIdCode; return this; } - } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Segment { - /** The flight segment amount. */ - @SerializedName("amount") - Long amount; + /** The phone number of the station. */ + public Builder setPhoneNumber(String phoneNumber) { + this.phoneNumber = phoneNumber; + return this; + } - /** - * The International Air Transport Association (IATA) airport code for the arrival airport. - */ - @SerializedName("arrival_airport") - Object arrivalAirport; + /** The phone number of the station. */ + public Builder setPhoneNumber(EmptyParam phoneNumber) { + this.phoneNumber = phoneNumber; + return this; + } - /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ - @SerializedName("arrives_at") - Long arrivesAt; + /** The physical location of the station. */ + public Builder setServiceLocation( + PaymentIntentUpdateParams.PaymentDetails.FleetData.Station.ServiceLocation + serviceLocation) { + this.serviceLocation = serviceLocation; + return this; + } - /** - * The International Air Transport Association (IATA) carrier code of the carrier operating - * the flight segment. - */ - @SerializedName("carrier") - Object carrier; + /** The URL of the station. */ + public Builder setUrl(String url) { + this.url = url; + return this; + } - /** - * Required. The departure time for the flight segment. Measured in seconds - * since the Unix epoch. - */ - @SerializedName("departs_at") - Long departsAt; - - /** - * The International Air Transport Association (IATA) airport code for the departure - * airport. - */ - @SerializedName("departure_airport") - Object departureAirport; - - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; - - /** The flight number associated with the segment. */ - @SerializedName("flight_number") - Object flightNumber; - - /** The fare class for the segment. */ - @SerializedName("service_class") - ServiceClass serviceClass; - - private Segment( - Long amount, - Object arrivalAirport, - Long arrivesAt, - Object carrier, - Long departsAt, - Object departureAirport, - Map extraParams, - Object flightNumber, - ServiceClass serviceClass) { - this.amount = amount; - this.arrivalAirport = arrivalAirport; - this.arrivesAt = arrivesAt; - this.carrier = carrier; - this.departsAt = departsAt; - this.departureAirport = departureAirport; - this.extraParams = extraParams; - this.flightNumber = flightNumber; - this.serviceClass = serviceClass; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private Long amount; - - private Object arrivalAirport; - - private Long arrivesAt; - - private Object carrier; - - private Long departsAt; - - private Object departureAirport; - - private Map extraParams; - - private Object flightNumber; - - private ServiceClass serviceClass; - - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.Flight.Segment build() { - return new PaymentIntentUpdateParams.PaymentDetails.Flight.Segment( - this.amount, - this.arrivalAirport, - this.arrivesAt, - this.carrier, - this.departsAt, - this.departureAirport, - this.extraParams, - this.flightNumber, - this.serviceClass); - } - - /** The flight segment amount. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } - - /** - * The International Air Transport Association (IATA) airport code for the arrival - * airport. - */ - public Builder setArrivalAirport(String arrivalAirport) { - this.arrivalAirport = arrivalAirport; - return this; - } - - /** - * The International Air Transport Association (IATA) airport code for the arrival - * airport. - */ - public Builder setArrivalAirport(EmptyParam arrivalAirport) { - this.arrivalAirport = arrivalAirport; + /** The URL of the station. */ + public Builder setUrl(EmptyParam url) { + this.url = url; return this; } + } - /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ - public Builder setArrivesAt(Long arrivesAt) { - this.arrivesAt = arrivesAt; - return this; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ServiceLocation { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + Object city; /** - * The International Air Transport Association (IATA) carrier code of the carrier - * operating the flight segment. + * Two-letter country code (ISO + * 3166-1 alpha-2). */ - public Builder setCarrier(String carrier) { - this.carrier = carrier; - return this; - } + @SerializedName("country") + Object country; /** - * The International Air Transport Association (IATA) carrier code of the carrier - * operating the flight segment. + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. */ - public Builder setCarrier(EmptyParam carrier) { - this.carrier = carrier; - return this; - } + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; /** - * Required. The departure time for the flight segment. Measured in - * seconds since the Unix epoch. + * Required. Address line 1, such as the street, PO Box, or company name. */ - public Builder setDepartsAt(Long departsAt) { - this.departsAt = departsAt; - return this; - } + @SerializedName("line1") + Object line1; - /** - * The International Air Transport Association (IATA) airport code for the departure - * airport. - */ - public Builder setDepartureAirport(String departureAirport) { - this.departureAirport = departureAirport; - return this; - } + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + Object line2; - /** - * The International Air Transport Association (IATA) airport code for the departure - * airport. - */ - public Builder setDepartureAirport(EmptyParam departureAirport) { - this.departureAirport = departureAirport; - return this; - } + /** ZIP or postal code. */ + @SerializedName("postal_code") + Object postalCode; /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight.Segment#extraParams} - * for the field documentation. + * State, county, province, or region (ISO 3166-2). */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + @SerializedName("state") + Object state; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight.Segment#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; + private ServiceLocation( + Object city, + Object country, + Map extraParams, + Object line1, + Object line2, + Object postalCode, + Object state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; } - /** The flight number associated with the segment. */ - public Builder setFlightNumber(String flightNumber) { - this.flightNumber = flightNumber; - return this; + public static Builder builder() { + return new Builder(); } - /** The flight number associated with the segment. */ - public Builder setFlightNumber(EmptyParam flightNumber) { - this.flightNumber = flightNumber; - return this; - } + public static class Builder { + private Object city; - /** The fare class for the segment. */ - public Builder setServiceClass( - PaymentIntentUpdateParams.PaymentDetails.Flight.Segment.ServiceClass serviceClass) { - this.serviceClass = serviceClass; - return this; - } - } + private Object country; - public enum ServiceClass implements ApiRequestParams.EnumParam { - @SerializedName("business") - BUSINESS("business"), + private Map extraParams; - @SerializedName("economy") - ECONOMY("economy"), + private Object line1; - @SerializedName("first") - FIRST("first"), + private Object line2; - @SerializedName("premium_economy") - PREMIUM_ECONOMY("premium_economy"); + private Object postalCode; - @Getter(onMethod_ = {@Override}) - private final String value; + private Object state; - ServiceClass(String value) { - this.value = value; + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.FleetData.Station.ServiceLocation + build() { + return new PaymentIntentUpdateParams.PaymentDetails.FleetData.Station.ServiceLocation( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } + + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** City, district, suburb, town, or village. */ + public Builder setCity(EmptyParam city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(EmptyParam country) { + this.country = country; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FleetData.Station.ServiceLocation#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FleetData.Station.ServiceLocation#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. Address line 1, such as the street, PO Box, or company + * name. + */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } + + /** + * Required. Address line 1, such as the street, PO Box, or company + * name. + */ + public Builder setLine1(EmptyParam line1) { + this.line1 = line1; + return this; + } + + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } + + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(EmptyParam line2) { + this.line2 = line2; + return this; + } + + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } + + /** ZIP or postal code. */ + public Builder setPostalCode(EmptyParam postalCode) { + this.postalCode = postalCode; + return this; + } + + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(EmptyParam state) { + this.state = state; + return this; + } + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Vat { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** + * Required. Indicates the merchant's agreement for Invoice on Behalf (IOB) + * VAT processing. + */ + @SerializedName("iob_indicator") + IobIndicator iobIndicator; + + private Vat(Map extraParams, IobIndicator iobIndicator) { + this.extraParams = extraParams; + this.iobIndicator = iobIndicator; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private IobIndicator iobIndicator; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.FleetData.Vat build() { + return new PaymentIntentUpdateParams.PaymentDetails.FleetData.Vat( + this.extraParams, this.iobIndicator); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.FleetData.Vat#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.FleetData.Vat#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. Indicates the merchant's agreement for Invoice on Behalf + * (IOB) VAT processing. + */ + public Builder setIobIndicator( + PaymentIntentUpdateParams.PaymentDetails.FleetData.Vat.IobIndicator iobIndicator) { + this.iobIndicator = iobIndicator; + return this; + } + } + + public enum IobIndicator implements ApiRequestParams.EnumParam { + @SerializedName("issuer_to_iob") + ISSUER_TO_IOB("issuer_to_iob"), + + @SerializedName("issuer_to_iob_and_incremental_certification") + ISSUER_TO_IOB_AND_INCREMENTAL_CERTIFICATION( + "issuer_to_iob_and_incremental_certification"), + + @SerializedName("merchant_does_not_agree_to_iob") + MERCHANT_DOES_NOT_AGREE_TO_IOB("merchant_does_not_agree_to_iob"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + IobIndicator(String value) { + this.value = value; } } } @@ -9583,22 +10089,28 @@ public enum ServiceClass implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class FlightData { - /** Affiliate details if applicable. */ + public static class Flight { + /** Affiliate details for this purchase. */ @SerializedName("affiliate") Affiliate affiliate; - /** Reservation reference. */ - @SerializedName("booking_number") - Object bookingNumber; + /** + * The agency number (i.e. International Air Transport Association (IATA) agency number) of + * the travel agency that made the booking. + */ + @SerializedName("agency_number") + Object agencyNumber; - /** Computerized reservation system used to make the reservation and purchase the ticket. */ - @SerializedName("computerized_reservation_system") - Object computerizedReservationSystem; + /** + * The International Air Transport Association (IATA) carrier code of the carrier that issued + * the ticket. + */ + @SerializedName("carrier") + Object carrier; - /** Ticket restrictions. */ - @SerializedName("endorsements_and_restrictions") - Object endorsementsAndRestrictions; + /** Delivery details for this purchase. */ + @SerializedName("delivery") + Delivery delivery; /** * Map of extra parameters for custom features not available in this client library. The @@ -9609,53 +10121,41 @@ public static class FlightData { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** List of insurances. */ - @SerializedName("insurances") - List insurances; + /** The name of the person or entity on the reservation. */ + @SerializedName("passenger_name") + Object passengerName; - /** List of passengers. */ + /** The details of the passengers in the travel reservation. */ @SerializedName("passengers") - List passengers; + List passengers; - /** Required. List of flight segments. */ + /** Required. The individual flight segments associated with the trip. */ @SerializedName("segments") - List segments; - - /** Electronic ticket indicator. */ - @SerializedName("ticket_electronically_issued_indicator") - Boolean ticketElectronicallyIssuedIndicator; - - /** Required. Total cost breakdown. */ - @SerializedName("total") - Total total; + List segments; - /** Type of flight transaction. */ - @SerializedName("transaction_type") - TransactionType transactionType; + /** The ticket number associated with the travel reservation. */ + @SerializedName("ticket_number") + Object ticketNumber; - private FlightData( + private Flight( Affiliate affiliate, - Object bookingNumber, - Object computerizedReservationSystem, - Object endorsementsAndRestrictions, + Object agencyNumber, + Object carrier, + Delivery delivery, Map extraParams, - List insurances, - List passengers, - List segments, - Boolean ticketElectronicallyIssuedIndicator, - Total total, - TransactionType transactionType) { + Object passengerName, + List passengers, + List segments, + Object ticketNumber) { this.affiliate = affiliate; - this.bookingNumber = bookingNumber; - this.computerizedReservationSystem = computerizedReservationSystem; - this.endorsementsAndRestrictions = endorsementsAndRestrictions; + this.agencyNumber = agencyNumber; + this.carrier = carrier; + this.delivery = delivery; this.extraParams = extraParams; - this.insurances = insurances; + this.passengerName = passengerName; this.passengers = passengers; this.segments = segments; - this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; - this.total = total; - this.transactionType = transactionType; + this.ticketNumber = ticketNumber; } public static Builder builder() { @@ -9665,89 +10165,90 @@ public static Builder builder() { public static class Builder { private Affiliate affiliate; - private Object bookingNumber; + private Object agencyNumber; - private Object computerizedReservationSystem; + private Object carrier; - private Object endorsementsAndRestrictions; + private Delivery delivery; private Map extraParams; - private List insurances; - - private List passengers; - - private List segments; + private Object passengerName; - private Boolean ticketElectronicallyIssuedIndicator; + private List passengers; - private Total total; + private List segments; - private TransactionType transactionType; + private Object ticketNumber; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.FlightData build() { - return new PaymentIntentUpdateParams.PaymentDetails.FlightData( + public PaymentIntentUpdateParams.PaymentDetails.Flight build() { + return new PaymentIntentUpdateParams.PaymentDetails.Flight( this.affiliate, - this.bookingNumber, - this.computerizedReservationSystem, - this.endorsementsAndRestrictions, + this.agencyNumber, + this.carrier, + this.delivery, this.extraParams, - this.insurances, + this.passengerName, this.passengers, this.segments, - this.ticketElectronicallyIssuedIndicator, - this.total, - this.transactionType); + this.ticketNumber); } - /** Affiliate details if applicable. */ + /** Affiliate details for this purchase. */ public Builder setAffiliate( - PaymentIntentUpdateParams.PaymentDetails.FlightData.Affiliate affiliate) { + PaymentIntentUpdateParams.PaymentDetails.Flight.Affiliate affiliate) { this.affiliate = affiliate; return this; } - /** Reservation reference. */ - public Builder setBookingNumber(String bookingNumber) { - this.bookingNumber = bookingNumber; - return this; - } - - /** Reservation reference. */ - public Builder setBookingNumber(EmptyParam bookingNumber) { - this.bookingNumber = bookingNumber; + /** + * The agency number (i.e. International Air Transport Association (IATA) agency number) of + * the travel agency that made the booking. + */ + public Builder setAgencyNumber(String agencyNumber) { + this.agencyNumber = agencyNumber; return this; } - /** Computerized reservation system used to make the reservation and purchase the ticket. */ - public Builder setComputerizedReservationSystem(String computerizedReservationSystem) { - this.computerizedReservationSystem = computerizedReservationSystem; + /** + * The agency number (i.e. International Air Transport Association (IATA) agency number) of + * the travel agency that made the booking. + */ + public Builder setAgencyNumber(EmptyParam agencyNumber) { + this.agencyNumber = agencyNumber; return this; } - /** Computerized reservation system used to make the reservation and purchase the ticket. */ - public Builder setComputerizedReservationSystem(EmptyParam computerizedReservationSystem) { - this.computerizedReservationSystem = computerizedReservationSystem; + /** + * The International Air Transport Association (IATA) carrier code of the carrier that + * issued the ticket. + */ + public Builder setCarrier(String carrier) { + this.carrier = carrier; return this; } - /** Ticket restrictions. */ - public Builder setEndorsementsAndRestrictions(String endorsementsAndRestrictions) { - this.endorsementsAndRestrictions = endorsementsAndRestrictions; + /** + * The International Air Transport Association (IATA) carrier code of the carrier that + * issued the ticket. + */ + public Builder setCarrier(EmptyParam carrier) { + this.carrier = carrier; return this; } - /** Ticket restrictions. */ - public Builder setEndorsementsAndRestrictions(EmptyParam endorsementsAndRestrictions) { - this.endorsementsAndRestrictions = endorsementsAndRestrictions; + /** Delivery details for this purchase. */ + public Builder setDelivery( + PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery delivery) { + this.delivery = delivery; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.FlightData#extraParams} for the + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight#extraParams} for the * field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -9761,7 +10262,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.FlightData#extraParams} for the + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight#extraParams} for the * field documentation. */ public Builder putAllExtraParam(Map map) { @@ -9772,44 +10273,25 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Add an element to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.FlightData#insurances} for the field - * documentation. - */ - public Builder addInsurance( - PaymentIntentUpdateParams.PaymentDetails.FlightData.Insurance element) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); - } - this.insurances.add(element); + /** The name of the person or entity on the reservation. */ + public Builder setPassengerName(String passengerName) { + this.passengerName = passengerName; return this; } - /** - * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.FlightData#insurances} for the field - * documentation. - */ - public Builder addAllInsurance( - List elements) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); - } - this.insurances.addAll(elements); + /** The name of the person or entity on the reservation. */ + public Builder setPassengerName(EmptyParam passengerName) { + this.passengerName = passengerName; return this; } /** * Add an element to `passengers` list. A list is initialized for the first `add/addAll` * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.FlightData#passengers} for the field - * documentation. + * PaymentIntentUpdateParams.PaymentDetails.Flight#passengers} for the field documentation. */ public Builder addPassenger( - PaymentIntentUpdateParams.PaymentDetails.FlightData.Passenger element) { + PaymentIntentUpdateParams.PaymentDetails.Flight.Passenger element) { if (this.passengers == null) { this.passengers = new ArrayList<>(); } @@ -9820,11 +10302,10 @@ public Builder addPassenger( /** * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.FlightData#passengers} for the field - * documentation. + * PaymentIntentUpdateParams.PaymentDetails.Flight#passengers} for the field documentation. */ public Builder addAllPassenger( - List elements) { + List elements) { if (this.passengers == null) { this.passengers = new ArrayList<>(); } @@ -9835,11 +10316,9 @@ public Builder addAllPassenger( /** * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, * and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.FlightData#segments} for the field - * documentation. + * PaymentIntentUpdateParams.PaymentDetails.Flight#segments} for the field documentation. */ - public Builder addSegment( - PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment element) { + public Builder addSegment(PaymentIntentUpdateParams.PaymentDetails.Flight.Segment element) { if (this.segments == null) { this.segments = new ArrayList<>(); } @@ -9850,11 +10329,10 @@ public Builder addSegment( /** * Add all elements to `segments` list. A list is initialized for the first `add/addAll` * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.FlightData#segments} for the field - * documentation. + * PaymentIntentUpdateParams.PaymentDetails.Flight#segments} for the field documentation. */ public Builder addAllSegment( - List elements) { + List elements) { if (this.segments == null) { this.segments = new ArrayList<>(); } @@ -9862,23 +10340,15 @@ public Builder addAllSegment( return this; } - /** Electronic ticket indicator. */ - public Builder setTicketElectronicallyIssuedIndicator( - Boolean ticketElectronicallyIssuedIndicator) { - this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; - return this; - } - - /** Required. Total cost breakdown. */ - public Builder setTotal(PaymentIntentUpdateParams.PaymentDetails.FlightData.Total total) { - this.total = total; + /** The ticket number associated with the travel reservation. */ + public Builder setTicketNumber(String ticketNumber) { + this.ticketNumber = ticketNumber; return this; } - /** Type of flight transaction. */ - public Builder setTransactionType( - PaymentIntentUpdateParams.PaymentDetails.FlightData.TransactionType transactionType) { - this.transactionType = transactionType; + /** The ticket number associated with the travel reservation. */ + public Builder setTicketNumber(EmptyParam ticketNumber) { + this.ticketNumber = ticketNumber; return this; } } @@ -9886,10 +10356,6 @@ public Builder setTransactionType( @Getter @EqualsAndHashCode(callSuper = false) public static class Affiliate { - /** Affiliate partner code. */ - @SerializedName("code") - Object code; - /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -9900,23 +10366,13 @@ public static class Affiliate { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Name of affiliate partner. */ + /** Required. The name of the affiliate that originated the purchase. */ @SerializedName("name") Object name; - /** Code provided by the company to a travel agent authorizing ticket issuance. */ - @SerializedName("travel_authorization_code") - Object travelAuthorizationCode; - - private Affiliate( - Object code, - Map extraParams, - Object name, - Object travelAuthorizationCode) { - this.code = code; + private Affiliate(Map extraParams, Object name) { this.extraParams = extraParams; this.name = name; - this.travelAuthorizationCode = travelAuthorizationCode; } public static Builder builder() { @@ -9924,38 +10380,21 @@ public static Builder builder() { } public static class Builder { - private Object code; - private Map extraParams; private Object name; - private Object travelAuthorizationCode; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.FlightData.Affiliate build() { - return new PaymentIntentUpdateParams.PaymentDetails.FlightData.Affiliate( - this.code, this.extraParams, this.name, this.travelAuthorizationCode); - } - - /** Affiliate partner code. */ - public Builder setCode(String code) { - this.code = code; - return this; - } - - /** Affiliate partner code. */ - public Builder setCode(EmptyParam code) { - this.code = code; - return this; + public PaymentIntentUpdateParams.PaymentDetails.Flight.Affiliate build() { + return new PaymentIntentUpdateParams.PaymentDetails.Flight.Affiliate( + this.extraParams, this.name); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.FlightData.Affiliate#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight.Affiliate#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -9968,9 +10407,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.FlightData.Affiliate#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight.Affiliate#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -9980,43 +10418,23 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Name of affiliate partner. */ + /** Required. The name of the affiliate that originated the purchase. */ public Builder setName(String name) { this.name = name; return this; } - /** Name of affiliate partner. */ + /** Required. The name of the affiliate that originated the purchase. */ public Builder setName(EmptyParam name) { this.name = name; return this; } - - /** Code provided by the company to a travel agent authorizing ticket issuance. */ - public Builder setTravelAuthorizationCode(String travelAuthorizationCode) { - this.travelAuthorizationCode = travelAuthorizationCode; - return this; - } - - /** Code provided by the company to a travel agent authorizing ticket issuance. */ - public Builder setTravelAuthorizationCode(EmptyParam travelAuthorizationCode) { - this.travelAuthorizationCode = travelAuthorizationCode; - return this; - } - } - } + } + } @Getter @EqualsAndHashCode(callSuper = false) - public static class Insurance { - /** Required. Insurance cost. */ - @SerializedName("amount") - Long amount; - - /** Insurance currency. */ - @SerializedName("currency") - Object currency; - + public static class Delivery { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -10027,25 +10445,18 @@ public static class Insurance { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Insurance company name. */ - @SerializedName("insurance_company_name") - Object insuranceCompanyName; + /** The delivery method for the payment. */ + @SerializedName("mode") + Mode mode; - /** Required. Type of insurance. */ - @SerializedName("insurance_type") - InsuranceType insuranceType; + /** Details of the recipient. */ + @SerializedName("recipient") + Recipient recipient; - private Insurance( - Long amount, - Object currency, - Map extraParams, - Object insuranceCompanyName, - InsuranceType insuranceType) { - this.amount = amount; - this.currency = currency; + private Delivery(Map extraParams, Mode mode, Recipient recipient) { this.extraParams = extraParams; - this.insuranceCompanyName = insuranceCompanyName; - this.insuranceType = insuranceType; + this.mode = mode; + this.recipient = recipient; } public static Builder builder() { @@ -10053,50 +10464,23 @@ public static Builder builder() { } public static class Builder { - private Long amount; - - private Object currency; - private Map extraParams; - private Object insuranceCompanyName; + private Mode mode; - private InsuranceType insuranceType; + private Recipient recipient; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.FlightData.Insurance build() { - return new PaymentIntentUpdateParams.PaymentDetails.FlightData.Insurance( - this.amount, - this.currency, - this.extraParams, - this.insuranceCompanyName, - this.insuranceType); - } - - /** Required. Insurance cost. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } - - /** Insurance currency. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; - } - - /** Insurance currency. */ - public Builder setCurrency(EmptyParam currency) { - this.currency = currency; - return this; + public PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery build() { + return new PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery( + this.extraParams, this.mode, this.recipient); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.FlightData.Insurance#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -10109,9 +10493,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.FlightData.Insurance#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -10121,47 +10504,158 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Insurance company name. */ - public Builder setInsuranceCompanyName(String insuranceCompanyName) { - this.insuranceCompanyName = insuranceCompanyName; + /** The delivery method for the payment. */ + public Builder setMode( + PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery.Mode mode) { + this.mode = mode; return this; } - /** Insurance company name. */ - public Builder setInsuranceCompanyName(EmptyParam insuranceCompanyName) { - this.insuranceCompanyName = insuranceCompanyName; + /** Details of the recipient. */ + public Builder setRecipient( + PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery.Recipient recipient) { + this.recipient = recipient; return this; } + } - /** Required. Type of insurance. */ - public Builder setInsuranceType( - PaymentIntentUpdateParams.PaymentDetails.FlightData.Insurance.InsuranceType - insuranceType) { - this.insuranceType = insuranceType; - return this; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Recipient { + /** The email of the recipient the ticket is delivered to. */ + @SerializedName("email") + Object email; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The name of the recipient the ticket is delivered to. */ + @SerializedName("name") + Object name; + + /** The phone number of the recipient the ticket is delivered to. */ + @SerializedName("phone") + Object phone; + + private Recipient( + Object email, Map extraParams, Object name, Object phone) { + this.email = email; + this.extraParams = extraParams; + this.name = name; + this.phone = phone; } - } - public enum InsuranceType implements ApiRequestParams.EnumParam { - @SerializedName("baggage") - BAGGAGE("baggage"), + public static Builder builder() { + return new Builder(); + } - @SerializedName("bankruptcy") - BANKRUPTCY("bankruptcy"), + public static class Builder { + private Object email; - @SerializedName("cancelation") - CANCELATION("cancelation"), + private Map extraParams; - @SerializedName("emergency") - EMERGENCY("emergency"), + private Object name; - @SerializedName("medical") - MEDICAL("medical"); + private Object phone; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery.Recipient build() { + return new PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery.Recipient( + this.email, this.extraParams, this.name, this.phone); + } + + /** The email of the recipient the ticket is delivered to. */ + public Builder setEmail(String email) { + this.email = email; + return this; + } + + /** The email of the recipient the ticket is delivered to. */ + public Builder setEmail(EmptyParam email) { + this.email = email; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.Flight.Delivery.Recipient#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The name of the recipient the ticket is delivered to. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** The name of the recipient the ticket is delivered to. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } + + /** The phone number of the recipient the ticket is delivered to. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } + + /** The phone number of the recipient the ticket is delivered to. */ + public Builder setPhone(EmptyParam phone) { + this.phone = phone; + return this; + } + } + } + + public enum Mode implements ApiRequestParams.EnumParam { + @SerializedName("email") + EMAIL("email"), + + @SerializedName("phone") + PHONE("phone"), + + @SerializedName("pickup") + PICKUP("pickup"), + + @SerializedName("post") + POST("post"); @Getter(onMethod_ = {@Override}) private final String value; - InsuranceType(String value) { + Mode(String value) { this.value = value; } } @@ -10180,7 +10674,9 @@ public static class Passenger { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Required. Passenger's full name. */ + /** + * Required. Full name of the person or entity on the flight reservation. + */ @SerializedName("name") Object name; @@ -10199,17 +10695,16 @@ public static class Builder { private Object name; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.FlightData.Passenger build() { - return new PaymentIntentUpdateParams.PaymentDetails.FlightData.Passenger( + public PaymentIntentUpdateParams.PaymentDetails.Flight.Passenger build() { + return new PaymentIntentUpdateParams.PaymentDetails.Flight.Passenger( this.extraParams, this.name); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.FlightData.Passenger#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight.Passenger#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -10222,9 +10717,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.FlightData.Passenger#extraParams} for the - * field documentation. + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight.Passenger#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -10234,13 +10728,17 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Required. Passenger's full name. */ + /** + * Required. Full name of the person or entity on the flight reservation. + */ public Builder setName(String name) { this.name = name; return this; } - /** Required. Passenger's full name. */ + /** + * Required. Full name of the person or entity on the flight reservation. + */ public Builder setName(EmptyParam name) { this.name = name; return this; @@ -10251,33 +10749,40 @@ public Builder setName(EmptyParam name) { @Getter @EqualsAndHashCode(callSuper = false) public static class Segment { - /** Segment fare amount. */ + /** The flight segment amount. */ @SerializedName("amount") Long amount; - /** Required. Arrival details. */ - @SerializedName("arrival") - Arrival arrival; - - /** Required. Airline carrier code. */ - @SerializedName("carrier_code") - Object carrierCode; + /** + * The International Air Transport Association (IATA) airport code for the arrival airport. + */ + @SerializedName("arrival_airport") + Object arrivalAirport; - /** Carrier name. */ - @SerializedName("carrier_name") - Object carrierName; + /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ + @SerializedName("arrives_at") + Long arrivesAt; - /** Segment currency. */ - @SerializedName("currency") - Object currency; + /** + * The International Air Transport Association (IATA) carrier code of the carrier operating + * the flight segment. + */ + @SerializedName("carrier") + Object carrier; - /** Required. Departure details. */ - @SerializedName("departure") - Departure departure; + /** + * Required. The departure time for the flight segment. Measured in seconds + * since the Unix epoch. + */ + @SerializedName("departs_at") + Long departsAt; - /** Exchange ticket number. */ - @SerializedName("exchange_ticket_number") - Object exchangeTicketNumber; + /** + * The International Air Transport Association (IATA) airport code for the departure + * airport. + */ + @SerializedName("departure_airport") + Object departureAirport; /** * Map of extra parameters for custom features not available in this client library. The @@ -10289,71 +10794,33 @@ public static class Segment { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Fare basis code. */ - @SerializedName("fare_basis_code") - Object fareBasisCode; - - /** Additional fees. */ - @SerializedName("fees") - Long fees; - - /** Flight number. */ + /** The flight number associated with the segment. */ @SerializedName("flight_number") Object flightNumber; - /** Stopover indicator. */ - @SerializedName("is_stop_over_indicator") - Boolean isStopOverIndicator; - - /** Refundable ticket indicator. */ - @SerializedName("refundable") - Boolean refundable; - - /** Required. Class of service. */ + /** The fare class for the segment. */ @SerializedName("service_class") ServiceClass serviceClass; - /** Tax amount for segment. */ - @SerializedName("tax_amount") - Long taxAmount; - - /** Ticket number. */ - @SerializedName("ticket_number") - Object ticketNumber; - private Segment( Long amount, - Arrival arrival, - Object carrierCode, - Object carrierName, - Object currency, - Departure departure, - Object exchangeTicketNumber, + Object arrivalAirport, + Long arrivesAt, + Object carrier, + Long departsAt, + Object departureAirport, Map extraParams, - Object fareBasisCode, - Long fees, Object flightNumber, - Boolean isStopOverIndicator, - Boolean refundable, - ServiceClass serviceClass, - Long taxAmount, - Object ticketNumber) { + ServiceClass serviceClass) { this.amount = amount; - this.arrival = arrival; - this.carrierCode = carrierCode; - this.carrierName = carrierName; - this.currency = currency; - this.departure = departure; - this.exchangeTicketNumber = exchangeTicketNumber; + this.arrivalAirport = arrivalAirport; + this.arrivesAt = arrivesAt; + this.carrier = carrier; + this.departsAt = departsAt; + this.departureAirport = departureAirport; this.extraParams = extraParams; - this.fareBasisCode = fareBasisCode; - this.fees = fees; this.flightNumber = flightNumber; - this.isStopOverIndicator = isStopOverIndicator; - this.refundable = refundable; this.serviceClass = serviceClass; - this.taxAmount = taxAmount; - this.ticketNumber = ticketNumber; } public static Builder builder() { @@ -10363,131 +10830,116 @@ public static Builder builder() { public static class Builder { private Long amount; - private Arrival arrival; - - private Object carrierCode; + private Object arrivalAirport; - private Object carrierName; + private Long arrivesAt; - private Object currency; + private Object carrier; - private Departure departure; + private Long departsAt; - private Object exchangeTicketNumber; + private Object departureAirport; private Map extraParams; - private Object fareBasisCode; - - private Long fees; - private Object flightNumber; - private Boolean isStopOverIndicator; - - private Boolean refundable; - private ServiceClass serviceClass; - private Long taxAmount; - - private Object ticketNumber; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment build() { - return new PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment( + public PaymentIntentUpdateParams.PaymentDetails.Flight.Segment build() { + return new PaymentIntentUpdateParams.PaymentDetails.Flight.Segment( this.amount, - this.arrival, - this.carrierCode, - this.carrierName, - this.currency, - this.departure, - this.exchangeTicketNumber, + this.arrivalAirport, + this.arrivesAt, + this.carrier, + this.departsAt, + this.departureAirport, this.extraParams, - this.fareBasisCode, - this.fees, this.flightNumber, - this.isStopOverIndicator, - this.refundable, - this.serviceClass, - this.taxAmount, - this.ticketNumber); + this.serviceClass); } - /** Segment fare amount. */ + /** The flight segment amount. */ public Builder setAmount(Long amount) { this.amount = amount; return this; } - /** Required. Arrival details. */ - public Builder setArrival( - PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment.Arrival arrival) { - this.arrival = arrival; - return this; - } - - /** Required. Airline carrier code. */ - public Builder setCarrierCode(String carrierCode) { - this.carrierCode = carrierCode; + /** + * The International Air Transport Association (IATA) airport code for the arrival + * airport. + */ + public Builder setArrivalAirport(String arrivalAirport) { + this.arrivalAirport = arrivalAirport; return this; } - /** Required. Airline carrier code. */ - public Builder setCarrierCode(EmptyParam carrierCode) { - this.carrierCode = carrierCode; + /** + * The International Air Transport Association (IATA) airport code for the arrival + * airport. + */ + public Builder setArrivalAirport(EmptyParam arrivalAirport) { + this.arrivalAirport = arrivalAirport; return this; } - /** Carrier name. */ - public Builder setCarrierName(String carrierName) { - this.carrierName = carrierName; + /** The arrival time for the flight segment. Measured in seconds since the Unix epoch. */ + public Builder setArrivesAt(Long arrivesAt) { + this.arrivesAt = arrivesAt; return this; } - /** Carrier name. */ - public Builder setCarrierName(EmptyParam carrierName) { - this.carrierName = carrierName; + /** + * The International Air Transport Association (IATA) carrier code of the carrier + * operating the flight segment. + */ + public Builder setCarrier(String carrier) { + this.carrier = carrier; return this; } - /** Segment currency. */ - public Builder setCurrency(String currency) { - this.currency = currency; + /** + * The International Air Transport Association (IATA) carrier code of the carrier + * operating the flight segment. + */ + public Builder setCarrier(EmptyParam carrier) { + this.carrier = carrier; return this; } - /** Segment currency. */ - public Builder setCurrency(EmptyParam currency) { - this.currency = currency; + /** + * Required. The departure time for the flight segment. Measured in + * seconds since the Unix epoch. + */ + public Builder setDepartsAt(Long departsAt) { + this.departsAt = departsAt; return this; } - /** Required. Departure details. */ - public Builder setDeparture( - PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment.Departure departure) { - this.departure = departure; + /** + * The International Air Transport Association (IATA) airport code for the departure + * airport. + */ + public Builder setDepartureAirport(String departureAirport) { + this.departureAirport = departureAirport; return this; } - /** Exchange ticket number. */ - public Builder setExchangeTicketNumber(String exchangeTicketNumber) { - this.exchangeTicketNumber = exchangeTicketNumber; - return this; - } - - /** Exchange ticket number. */ - public Builder setExchangeTicketNumber(EmptyParam exchangeTicketNumber) { - this.exchangeTicketNumber = exchangeTicketNumber; + /** + * The International Air Transport Association (IATA) airport code for the departure + * airport. + */ + public Builder setDepartureAirport(EmptyParam departureAirport) { + this.departureAirport = departureAirport; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment#extraParams} for the field - * documentation. + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight.Segment#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -10500,9 +10952,8 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment#extraParams} for the field - * documentation. + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Flight.Segment#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -10512,188 +10963,1162 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Fare basis code. */ - public Builder setFareBasisCode(String fareBasisCode) { - this.fareBasisCode = fareBasisCode; - return this; - } - - /** Fare basis code. */ - public Builder setFareBasisCode(EmptyParam fareBasisCode) { - this.fareBasisCode = fareBasisCode; - return this; - } - - /** Additional fees. */ - public Builder setFees(Long fees) { - this.fees = fees; - return this; - } - - /** Flight number. */ + /** The flight number associated with the segment. */ public Builder setFlightNumber(String flightNumber) { this.flightNumber = flightNumber; return this; } - /** Flight number. */ + /** The flight number associated with the segment. */ public Builder setFlightNumber(EmptyParam flightNumber) { this.flightNumber = flightNumber; return this; } - /** Stopover indicator. */ - public Builder setIsStopOverIndicator(Boolean isStopOverIndicator) { - this.isStopOverIndicator = isStopOverIndicator; - return this; - } - - /** Refundable ticket indicator. */ - public Builder setRefundable(Boolean refundable) { - this.refundable = refundable; - return this; - } - - /** Required. Class of service. */ + /** The fare class for the segment. */ public Builder setServiceClass( - PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment.ServiceClass - serviceClass) { + PaymentIntentUpdateParams.PaymentDetails.Flight.Segment.ServiceClass serviceClass) { this.serviceClass = serviceClass; return this; } + } - /** Tax amount for segment. */ - public Builder setTaxAmount(Long taxAmount) { - this.taxAmount = taxAmount; - return this; - } + public enum ServiceClass implements ApiRequestParams.EnumParam { + @SerializedName("business") + BUSINESS("business"), - /** Ticket number. */ - public Builder setTicketNumber(String ticketNumber) { - this.ticketNumber = ticketNumber; - return this; - } + @SerializedName("economy") + ECONOMY("economy"), - /** Ticket number. */ - public Builder setTicketNumber(EmptyParam ticketNumber) { - this.ticketNumber = ticketNumber; - return this; + @SerializedName("first") + FIRST("first"), + + @SerializedName("premium_economy") + PREMIUM_ECONOMY("premium_economy"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ServiceClass(String value) { + this.value = value; } } + } + } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Arrival { - /** Required. Arrival airport IATA code. */ - @SerializedName("airport") - Object airport; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class FlightData { + /** Affiliate details if applicable. */ + @SerializedName("affiliate") + Affiliate affiliate; - /** Arrival date/time. */ - @SerializedName("arrives_at") - Long arrivesAt; + /** Reservation reference. */ + @SerializedName("booking_number") + Object bookingNumber; - /** Arrival city. */ - @SerializedName("city") - Object city; + /** Computerized reservation system used to make the reservation and purchase the ticket. */ + @SerializedName("computerized_reservation_system") + Object computerizedReservationSystem; - /** Arrival country. */ - @SerializedName("country") - Object country; + /** Ticket restrictions. */ + @SerializedName("endorsements_and_restrictions") + Object endorsementsAndRestrictions; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private Arrival( - Object airport, - Long arrivesAt, - Object city, - Object country, - Map extraParams) { - this.airport = airport; - this.arrivesAt = arrivesAt; - this.city = city; - this.country = country; - this.extraParams = extraParams; - } + /** List of insurances. */ + @SerializedName("insurances") + List insurances; - public static Builder builder() { - return new Builder(); - } + /** List of passengers. */ + @SerializedName("passengers") + List passengers; - public static class Builder { - private Object airport; + /** Required. List of flight segments. */ + @SerializedName("segments") + List segments; - private Long arrivesAt; + /** Electronic ticket indicator. */ + @SerializedName("ticket_electronically_issued_indicator") + Boolean ticketElectronicallyIssuedIndicator; - private Object city; + /** Required. Total cost breakdown. */ + @SerializedName("total") + Total total; - private Object country; + /** Type of flight transaction. */ + @SerializedName("transaction_type") + TransactionType transactionType; - private Map extraParams; + private FlightData( + Affiliate affiliate, + Object bookingNumber, + Object computerizedReservationSystem, + Object endorsementsAndRestrictions, + Map extraParams, + List insurances, + List passengers, + List segments, + Boolean ticketElectronicallyIssuedIndicator, + Total total, + TransactionType transactionType) { + this.affiliate = affiliate; + this.bookingNumber = bookingNumber; + this.computerizedReservationSystem = computerizedReservationSystem; + this.endorsementsAndRestrictions = endorsementsAndRestrictions; + this.extraParams = extraParams; + this.insurances = insurances; + this.passengers = passengers; + this.segments = segments; + this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; + this.total = total; + this.transactionType = transactionType; + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment.Arrival build() { - return new PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment.Arrival( - this.airport, this.arrivesAt, this.city, this.country, this.extraParams); - } + public static Builder builder() { + return new Builder(); + } - /** Required. Arrival airport IATA code. */ - public Builder setAirport(String airport) { - this.airport = airport; - return this; - } + public static class Builder { + private Affiliate affiliate; - /** Required. Arrival airport IATA code. */ - public Builder setAirport(EmptyParam airport) { - this.airport = airport; - return this; - } + private Object bookingNumber; - /** Arrival date/time. */ - public Builder setArrivesAt(Long arrivesAt) { - this.arrivesAt = arrivesAt; - return this; - } + private Object computerizedReservationSystem; - /** Arrival city. */ - public Builder setCity(String city) { - this.city = city; - return this; - } + private Object endorsementsAndRestrictions; - /** Arrival city. */ - public Builder setCity(EmptyParam city) { - this.city = city; - return this; - } + private Map extraParams; - /** Arrival country. */ - public Builder setCountry(String country) { - this.country = country; - return this; - } + private List insurances; - /** Arrival country. */ - public Builder setCountry(EmptyParam country) { - this.country = country; - return this; - } + private List passengers; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment.Arrival#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { + private List segments; + + private Boolean ticketElectronicallyIssuedIndicator; + + private Total total; + + private TransactionType transactionType; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.FlightData build() { + return new PaymentIntentUpdateParams.PaymentDetails.FlightData( + this.affiliate, + this.bookingNumber, + this.computerizedReservationSystem, + this.endorsementsAndRestrictions, + this.extraParams, + this.insurances, + this.passengers, + this.segments, + this.ticketElectronicallyIssuedIndicator, + this.total, + this.transactionType); + } + + /** Affiliate details if applicable. */ + public Builder setAffiliate( + PaymentIntentUpdateParams.PaymentDetails.FlightData.Affiliate affiliate) { + this.affiliate = affiliate; + return this; + } + + /** Reservation reference. */ + public Builder setBookingNumber(String bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } + + /** Reservation reference. */ + public Builder setBookingNumber(EmptyParam bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } + + /** Computerized reservation system used to make the reservation and purchase the ticket. */ + public Builder setComputerizedReservationSystem(String computerizedReservationSystem) { + this.computerizedReservationSystem = computerizedReservationSystem; + return this; + } + + /** Computerized reservation system used to make the reservation and purchase the ticket. */ + public Builder setComputerizedReservationSystem(EmptyParam computerizedReservationSystem) { + this.computerizedReservationSystem = computerizedReservationSystem; + return this; + } + + /** Ticket restrictions. */ + public Builder setEndorsementsAndRestrictions(String endorsementsAndRestrictions) { + this.endorsementsAndRestrictions = endorsementsAndRestrictions; + return this; + } + + /** Ticket restrictions. */ + public Builder setEndorsementsAndRestrictions(EmptyParam endorsementsAndRestrictions) { + this.endorsementsAndRestrictions = endorsementsAndRestrictions; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.FlightData#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.FlightData#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Add an element to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FlightData#insurances} for the field + * documentation. + */ + public Builder addInsurance( + PaymentIntentUpdateParams.PaymentDetails.FlightData.Insurance element) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); + } + this.insurances.add(element); + return this; + } + + /** + * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FlightData#insurances} for the field + * documentation. + */ + public Builder addAllInsurance( + List elements) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); + } + this.insurances.addAll(elements); + return this; + } + + /** + * Add an element to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FlightData#passengers} for the field + * documentation. + */ + public Builder addPassenger( + PaymentIntentUpdateParams.PaymentDetails.FlightData.Passenger element) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.add(element); + return this; + } + + /** + * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FlightData#passengers} for the field + * documentation. + */ + public Builder addAllPassenger( + List elements) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.addAll(elements); + return this; + } + + /** + * Add an element to `segments` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FlightData#segments} for the field + * documentation. + */ + public Builder addSegment( + PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment element) { + if (this.segments == null) { + this.segments = new ArrayList<>(); + } + this.segments.add(element); + return this; + } + + /** + * Add all elements to `segments` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FlightData#segments} for the field + * documentation. + */ + public Builder addAllSegment( + List elements) { + if (this.segments == null) { + this.segments = new ArrayList<>(); + } + this.segments.addAll(elements); + return this; + } + + /** Electronic ticket indicator. */ + public Builder setTicketElectronicallyIssuedIndicator( + Boolean ticketElectronicallyIssuedIndicator) { + this.ticketElectronicallyIssuedIndicator = ticketElectronicallyIssuedIndicator; + return this; + } + + /** Required. Total cost breakdown. */ + public Builder setTotal(PaymentIntentUpdateParams.PaymentDetails.FlightData.Total total) { + this.total = total; + return this; + } + + /** Type of flight transaction. */ + public Builder setTransactionType( + PaymentIntentUpdateParams.PaymentDetails.FlightData.TransactionType transactionType) { + this.transactionType = transactionType; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Affiliate { + /** Affiliate partner code. */ + @SerializedName("code") + Object code; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Name of affiliate partner. */ + @SerializedName("name") + Object name; + + /** Code provided by the company to a travel agent authorizing ticket issuance. */ + @SerializedName("travel_authorization_code") + Object travelAuthorizationCode; + + private Affiliate( + Object code, + Map extraParams, + Object name, + Object travelAuthorizationCode) { + this.code = code; + this.extraParams = extraParams; + this.name = name; + this.travelAuthorizationCode = travelAuthorizationCode; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object code; + + private Map extraParams; + + private Object name; + + private Object travelAuthorizationCode; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.FlightData.Affiliate build() { + return new PaymentIntentUpdateParams.PaymentDetails.FlightData.Affiliate( + this.code, this.extraParams, this.name, this.travelAuthorizationCode); + } + + /** Affiliate partner code. */ + public Builder setCode(String code) { + this.code = code; + return this; + } + + /** Affiliate partner code. */ + public Builder setCode(EmptyParam code) { + this.code = code; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FlightData.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FlightData.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Name of affiliate partner. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** Name of affiliate partner. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } + + /** Code provided by the company to a travel agent authorizing ticket issuance. */ + public Builder setTravelAuthorizationCode(String travelAuthorizationCode) { + this.travelAuthorizationCode = travelAuthorizationCode; + return this; + } + + /** Code provided by the company to a travel agent authorizing ticket issuance. */ + public Builder setTravelAuthorizationCode(EmptyParam travelAuthorizationCode) { + this.travelAuthorizationCode = travelAuthorizationCode; + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Insurance { + /** Required. Insurance cost. */ + @SerializedName("amount") + Long amount; + + /** Insurance currency. */ + @SerializedName("currency") + Object currency; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Insurance company name. */ + @SerializedName("insurance_company_name") + Object insuranceCompanyName; + + /** Required. Type of insurance. */ + @SerializedName("insurance_type") + InsuranceType insuranceType; + + private Insurance( + Long amount, + Object currency, + Map extraParams, + Object insuranceCompanyName, + InsuranceType insuranceType) { + this.amount = amount; + this.currency = currency; + this.extraParams = extraParams; + this.insuranceCompanyName = insuranceCompanyName; + this.insuranceType = insuranceType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private Object currency; + + private Map extraParams; + + private Object insuranceCompanyName; + + private InsuranceType insuranceType; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.FlightData.Insurance build() { + return new PaymentIntentUpdateParams.PaymentDetails.FlightData.Insurance( + this.amount, + this.currency, + this.extraParams, + this.insuranceCompanyName, + this.insuranceType); + } + + /** Required. Insurance cost. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Insurance currency. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; + } + + /** Insurance currency. */ + public Builder setCurrency(EmptyParam currency) { + this.currency = currency; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FlightData.Insurance#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FlightData.Insurance#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Insurance company name. */ + public Builder setInsuranceCompanyName(String insuranceCompanyName) { + this.insuranceCompanyName = insuranceCompanyName; + return this; + } + + /** Insurance company name. */ + public Builder setInsuranceCompanyName(EmptyParam insuranceCompanyName) { + this.insuranceCompanyName = insuranceCompanyName; + return this; + } + + /** Required. Type of insurance. */ + public Builder setInsuranceType( + PaymentIntentUpdateParams.PaymentDetails.FlightData.Insurance.InsuranceType + insuranceType) { + this.insuranceType = insuranceType; + return this; + } + } + + public enum InsuranceType implements ApiRequestParams.EnumParam { + @SerializedName("baggage") + BAGGAGE("baggage"), + + @SerializedName("bankruptcy") + BANKRUPTCY("bankruptcy"), + + @SerializedName("cancelation") + CANCELATION("cancelation"), + + @SerializedName("emergency") + EMERGENCY("emergency"), + + @SerializedName("medical") + MEDICAL("medical"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + InsuranceType(String value) { + this.value = value; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Passenger { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Required. Passenger's full name. */ + @SerializedName("name") + Object name; + + private Passenger(Map extraParams, Object name) { + this.extraParams = extraParams; + this.name = name; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Object name; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.FlightData.Passenger build() { + return new PaymentIntentUpdateParams.PaymentDetails.FlightData.Passenger( + this.extraParams, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FlightData.Passenger#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FlightData.Passenger#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Required. Passenger's full name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** Required. Passenger's full name. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Segment { + /** Segment fare amount. */ + @SerializedName("amount") + Long amount; + + /** Required. Arrival details. */ + @SerializedName("arrival") + Arrival arrival; + + /** Required. Airline carrier code. */ + @SerializedName("carrier_code") + Object carrierCode; + + /** Carrier name. */ + @SerializedName("carrier_name") + Object carrierName; + + /** Segment currency. */ + @SerializedName("currency") + Object currency; + + /** Required. Departure details. */ + @SerializedName("departure") + Departure departure; + + /** Exchange ticket number. */ + @SerializedName("exchange_ticket_number") + Object exchangeTicketNumber; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Fare basis code. */ + @SerializedName("fare_basis_code") + Object fareBasisCode; + + /** Additional fees. */ + @SerializedName("fees") + Long fees; + + /** Flight number. */ + @SerializedName("flight_number") + Object flightNumber; + + /** Stopover indicator. */ + @SerializedName("is_stop_over_indicator") + Boolean isStopOverIndicator; + + /** Refundable ticket indicator. */ + @SerializedName("refundable") + Boolean refundable; + + /** Required. Class of service. */ + @SerializedName("service_class") + ServiceClass serviceClass; + + /** Tax amount for segment. */ + @SerializedName("tax_amount") + Long taxAmount; + + /** Ticket number. */ + @SerializedName("ticket_number") + Object ticketNumber; + + private Segment( + Long amount, + Arrival arrival, + Object carrierCode, + Object carrierName, + Object currency, + Departure departure, + Object exchangeTicketNumber, + Map extraParams, + Object fareBasisCode, + Long fees, + Object flightNumber, + Boolean isStopOverIndicator, + Boolean refundable, + ServiceClass serviceClass, + Long taxAmount, + Object ticketNumber) { + this.amount = amount; + this.arrival = arrival; + this.carrierCode = carrierCode; + this.carrierName = carrierName; + this.currency = currency; + this.departure = departure; + this.exchangeTicketNumber = exchangeTicketNumber; + this.extraParams = extraParams; + this.fareBasisCode = fareBasisCode; + this.fees = fees; + this.flightNumber = flightNumber; + this.isStopOverIndicator = isStopOverIndicator; + this.refundable = refundable; + this.serviceClass = serviceClass; + this.taxAmount = taxAmount; + this.ticketNumber = ticketNumber; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private Arrival arrival; + + private Object carrierCode; + + private Object carrierName; + + private Object currency; + + private Departure departure; + + private Object exchangeTicketNumber; + + private Map extraParams; + + private Object fareBasisCode; + + private Long fees; + + private Object flightNumber; + + private Boolean isStopOverIndicator; + + private Boolean refundable; + + private ServiceClass serviceClass; + + private Long taxAmount; + + private Object ticketNumber; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment build() { + return new PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment( + this.amount, + this.arrival, + this.carrierCode, + this.carrierName, + this.currency, + this.departure, + this.exchangeTicketNumber, + this.extraParams, + this.fareBasisCode, + this.fees, + this.flightNumber, + this.isStopOverIndicator, + this.refundable, + this.serviceClass, + this.taxAmount, + this.ticketNumber); + } + + /** Segment fare amount. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Required. Arrival details. */ + public Builder setArrival( + PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment.Arrival arrival) { + this.arrival = arrival; + return this; + } + + /** Required. Airline carrier code. */ + public Builder setCarrierCode(String carrierCode) { + this.carrierCode = carrierCode; + return this; + } + + /** Required. Airline carrier code. */ + public Builder setCarrierCode(EmptyParam carrierCode) { + this.carrierCode = carrierCode; + return this; + } + + /** Carrier name. */ + public Builder setCarrierName(String carrierName) { + this.carrierName = carrierName; + return this; + } + + /** Carrier name. */ + public Builder setCarrierName(EmptyParam carrierName) { + this.carrierName = carrierName; + return this; + } + + /** Segment currency. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; + } + + /** Segment currency. */ + public Builder setCurrency(EmptyParam currency) { + this.currency = currency; + return this; + } + + /** Required. Departure details. */ + public Builder setDeparture( + PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment.Departure departure) { + this.departure = departure; + return this; + } + + /** Exchange ticket number. */ + public Builder setExchangeTicketNumber(String exchangeTicketNumber) { + this.exchangeTicketNumber = exchangeTicketNumber; + return this; + } + + /** Exchange ticket number. */ + public Builder setExchangeTicketNumber(EmptyParam exchangeTicketNumber) { + this.exchangeTicketNumber = exchangeTicketNumber; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment#extraParams} for the field + * documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment#extraParams} for the field + * documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Fare basis code. */ + public Builder setFareBasisCode(String fareBasisCode) { + this.fareBasisCode = fareBasisCode; + return this; + } + + /** Fare basis code. */ + public Builder setFareBasisCode(EmptyParam fareBasisCode) { + this.fareBasisCode = fareBasisCode; + return this; + } + + /** Additional fees. */ + public Builder setFees(Long fees) { + this.fees = fees; + return this; + } + + /** Flight number. */ + public Builder setFlightNumber(String flightNumber) { + this.flightNumber = flightNumber; + return this; + } + + /** Flight number. */ + public Builder setFlightNumber(EmptyParam flightNumber) { + this.flightNumber = flightNumber; + return this; + } + + /** Stopover indicator. */ + public Builder setIsStopOverIndicator(Boolean isStopOverIndicator) { + this.isStopOverIndicator = isStopOverIndicator; + return this; + } + + /** Refundable ticket indicator. */ + public Builder setRefundable(Boolean refundable) { + this.refundable = refundable; + return this; + } + + /** Required. Class of service. */ + public Builder setServiceClass( + PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment.ServiceClass + serviceClass) { + this.serviceClass = serviceClass; + return this; + } + + /** Tax amount for segment. */ + public Builder setTaxAmount(Long taxAmount) { + this.taxAmount = taxAmount; + return this; + } + + /** Ticket number. */ + public Builder setTicketNumber(String ticketNumber) { + this.ticketNumber = ticketNumber; + return this; + } + + /** Ticket number. */ + public Builder setTicketNumber(EmptyParam ticketNumber) { + this.ticketNumber = ticketNumber; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Arrival { + /** Required. Arrival airport IATA code. */ + @SerializedName("airport") + Object airport; + + /** Arrival date/time. */ + @SerializedName("arrives_at") + Long arrivesAt; + + /** Arrival city. */ + @SerializedName("city") + Object city; + + /** Arrival country. */ + @SerializedName("country") + Object country; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Arrival( + Object airport, + Long arrivesAt, + Object city, + Object country, + Map extraParams) { + this.airport = airport; + this.arrivesAt = arrivesAt; + this.city = city; + this.country = country; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object airport; + + private Long arrivesAt; + + private Object city; + + private Object country; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment.Arrival build() { + return new PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment.Arrival( + this.airport, this.arrivesAt, this.city, this.country, this.extraParams); + } + + /** Required. Arrival airport IATA code. */ + public Builder setAirport(String airport) { + this.airport = airport; + return this; + } + + /** Required. Arrival airport IATA code. */ + public Builder setAirport(EmptyParam airport) { + this.airport = airport; + return this; + } + + /** Arrival date/time. */ + public Builder setArrivesAt(Long arrivesAt) { + this.arrivesAt = arrivesAt; + return this; + } + + /** Arrival city. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** Arrival city. */ + public Builder setCity(EmptyParam city) { + this.city = city; + return this; + } + + /** Arrival country. */ + public Builder setCountry(String country) { + this.country = country; + return this; + } + + /** Arrival country. */ + public Builder setCountry(EmptyParam country) { + this.country = country; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.FlightData.Segment.Arrival#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { this.extraParams = new HashMap<>(); } @@ -11531,468 +12956,741 @@ public static class Lodging { @SerializedName("category") Category category; - /** - * Required. Lodging check-in time. Measured in seconds since the Unix epoch. - */ - @SerializedName("checkin_at") - Long checkinAt; + /** + * Required. Lodging check-in time. Measured in seconds since the Unix epoch. + */ + @SerializedName("checkin_at") + Long checkinAt; + + /** + * Required. Lodging check-out time. Measured in seconds since the Unix + * epoch. + */ + @SerializedName("checkout_at") + Long checkoutAt; + + /** The customer service phone number of the lodging company. */ + @SerializedName("customer_service_phone_number") + Object customerServicePhoneNumber; + + /** The daily lodging room rate. */ + @SerializedName("daily_room_rate_amount") + Long dailyRoomRateAmount; + + /** Delivery details for this purchase. */ + @SerializedName("delivery") + Delivery delivery; + + /** List of additional charges being billed. */ + @SerializedName("extra_charges") + List extraCharges; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Indicates whether the lodging location is compliant with the Fire Safety Act. */ + @SerializedName("fire_safety_act_compliance") + Boolean fireSafetyActCompliance; + + /** The name of the lodging location. */ + @SerializedName("name") + Object name; + + /** + * Indicates if the customer did not keep their booking while failing to cancel the + * reservation. + */ + @SerializedName("no_show") + Boolean noShow; + + /** The number of rooms on the booking. */ + @SerializedName("number_of_rooms") + Long numberOfRooms; + + /** The details of the passengers in the travel reservation. */ + @SerializedName("passengers") + List passengers; + + /** The phone number of the lodging location. */ + @SerializedName("property_phone_number") + Object propertyPhoneNumber; + + /** The room class for this purchase. */ + @SerializedName("room_class") + Object roomClass; + + /** The number of room nights. */ + @SerializedName("room_nights") + Long roomNights; + + /** The total tax amount associating with the room reservation. */ + @SerializedName("total_room_tax_amount") + Long totalRoomTaxAmount; + + /** The total tax amount. */ + @SerializedName("total_tax_amount") + Long totalTaxAmount; + + private Lodging( + Address address, + Long adults, + Affiliate affiliate, + Object bookingNumber, + Category category, + Long checkinAt, + Long checkoutAt, + Object customerServicePhoneNumber, + Long dailyRoomRateAmount, + Delivery delivery, + List extraCharges, + Map extraParams, + Boolean fireSafetyActCompliance, + Object name, + Boolean noShow, + Long numberOfRooms, + List passengers, + Object propertyPhoneNumber, + Object roomClass, + Long roomNights, + Long totalRoomTaxAmount, + Long totalTaxAmount) { + this.address = address; + this.adults = adults; + this.affiliate = affiliate; + this.bookingNumber = bookingNumber; + this.category = category; + this.checkinAt = checkinAt; + this.checkoutAt = checkoutAt; + this.customerServicePhoneNumber = customerServicePhoneNumber; + this.dailyRoomRateAmount = dailyRoomRateAmount; + this.delivery = delivery; + this.extraCharges = extraCharges; + this.extraParams = extraParams; + this.fireSafetyActCompliance = fireSafetyActCompliance; + this.name = name; + this.noShow = noShow; + this.numberOfRooms = numberOfRooms; + this.passengers = passengers; + this.propertyPhoneNumber = propertyPhoneNumber; + this.roomClass = roomClass; + this.roomNights = roomNights; + this.totalRoomTaxAmount = totalRoomTaxAmount; + this.totalTaxAmount = totalTaxAmount; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Address address; + + private Long adults; + + private Affiliate affiliate; + + private Object bookingNumber; + + private Category category; + + private Long checkinAt; + + private Long checkoutAt; + + private Object customerServicePhoneNumber; + + private Long dailyRoomRateAmount; + + private Delivery delivery; + + private List extraCharges; + + private Map extraParams; + + private Boolean fireSafetyActCompliance; + + private Object name; + + private Boolean noShow; + + private Long numberOfRooms; + + private List passengers; + + private Object propertyPhoneNumber; + + private Object roomClass; + + private Long roomNights; + + private Long totalRoomTaxAmount; + + private Long totalTaxAmount; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.Lodging build() { + return new PaymentIntentUpdateParams.PaymentDetails.Lodging( + this.address, + this.adults, + this.affiliate, + this.bookingNumber, + this.category, + this.checkinAt, + this.checkoutAt, + this.customerServicePhoneNumber, + this.dailyRoomRateAmount, + this.delivery, + this.extraCharges, + this.extraParams, + this.fireSafetyActCompliance, + this.name, + this.noShow, + this.numberOfRooms, + this.passengers, + this.propertyPhoneNumber, + this.roomClass, + this.roomNights, + this.totalRoomTaxAmount, + this.totalTaxAmount); + } + + /** The lodging location's address. */ + public Builder setAddress( + PaymentIntentUpdateParams.PaymentDetails.Lodging.Address address) { + this.address = address; + return this; + } + + /** The number of adults on the booking. */ + public Builder setAdults(Long adults) { + this.adults = adults; + return this; + } + + /** Affiliate details for this purchase. */ + public Builder setAffiliate( + PaymentIntentUpdateParams.PaymentDetails.Lodging.Affiliate affiliate) { + this.affiliate = affiliate; + return this; + } + + /** The booking number associated with the lodging reservation. */ + public Builder setBookingNumber(String bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } + + /** The booking number associated with the lodging reservation. */ + public Builder setBookingNumber(EmptyParam bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } - /** - * Required. Lodging check-out time. Measured in seconds since the Unix - * epoch. - */ - @SerializedName("checkout_at") - Long checkoutAt; + /** The lodging category. */ + public Builder setCategory( + PaymentIntentUpdateParams.PaymentDetails.Lodging.Category category) { + this.category = category; + return this; + } - /** The customer service phone number of the lodging company. */ - @SerializedName("customer_service_phone_number") - Object customerServicePhoneNumber; + /** + * Required. Lodging check-in time. Measured in seconds since the Unix + * epoch. + */ + public Builder setCheckinAt(Long checkinAt) { + this.checkinAt = checkinAt; + return this; + } - /** The daily lodging room rate. */ - @SerializedName("daily_room_rate_amount") - Long dailyRoomRateAmount; + /** + * Required. Lodging check-out time. Measured in seconds since the Unix + * epoch. + */ + public Builder setCheckoutAt(Long checkoutAt) { + this.checkoutAt = checkoutAt; + return this; + } - /** Delivery details for this purchase. */ - @SerializedName("delivery") - Delivery delivery; + /** The customer service phone number of the lodging company. */ + public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; + } - /** List of additional charges being billed. */ - @SerializedName("extra_charges") - List extraCharges; + /** The customer service phone number of the lodging company. */ + public Builder setCustomerServicePhoneNumber(EmptyParam customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; + } - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) - * name in this param object. Effectively, this map is flattened to its parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** The daily lodging room rate. */ + public Builder setDailyRoomRateAmount(Long dailyRoomRateAmount) { + this.dailyRoomRateAmount = dailyRoomRateAmount; + return this; + } - /** Indicates whether the lodging location is compliant with the Fire Safety Act. */ - @SerializedName("fire_safety_act_compliance") - Boolean fireSafetyActCompliance; + /** Delivery details for this purchase. */ + public Builder setDelivery( + PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery delivery) { + this.delivery = delivery; + return this; + } - /** The name of the lodging location. */ - @SerializedName("name") - Object name; + /** + * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.Lodging#extraCharges} for the field + * documentation. + */ + public Builder addExtraCharge( + PaymentIntentUpdateParams.PaymentDetails.Lodging.ExtraCharge element) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.add(element); + return this; + } - /** - * Indicates if the customer did not keep their booking while failing to cancel the - * reservation. - */ - @SerializedName("no_show") - Boolean noShow; + /** + * Add all elements to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.Lodging#extraCharges} for the field + * documentation. + */ + public Builder addAllExtraCharge( + List elements) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.addAll(elements); + return this; + } - /** The number of rooms on the booking. */ - @SerializedName("number_of_rooms") - Long numberOfRooms; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** The details of the passengers in the travel reservation. */ - @SerializedName("passengers") - List passengers; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** The phone number of the lodging location. */ - @SerializedName("property_phone_number") - Object propertyPhoneNumber; + /** Indicates whether the lodging location is compliant with the Fire Safety Act. */ + public Builder setFireSafetyActCompliance(Boolean fireSafetyActCompliance) { + this.fireSafetyActCompliance = fireSafetyActCompliance; + return this; + } - /** The room class for this purchase. */ - @SerializedName("room_class") - Object roomClass; + /** The name of the lodging location. */ + public Builder setName(String name) { + this.name = name; + return this; + } - /** The number of room nights. */ - @SerializedName("room_nights") - Long roomNights; + /** The name of the lodging location. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } - /** The total tax amount associating with the room reservation. */ - @SerializedName("total_room_tax_amount") - Long totalRoomTaxAmount; + /** + * Indicates if the customer did not keep their booking while failing to cancel the + * reservation. + */ + public Builder setNoShow(Boolean noShow) { + this.noShow = noShow; + return this; + } - /** The total tax amount. */ - @SerializedName("total_tax_amount") - Long totalTaxAmount; + /** The number of rooms on the booking. */ + public Builder setNumberOfRooms(Long numberOfRooms) { + this.numberOfRooms = numberOfRooms; + return this; + } - private Lodging( - Address address, - Long adults, - Affiliate affiliate, - Object bookingNumber, - Category category, - Long checkinAt, - Long checkoutAt, - Object customerServicePhoneNumber, - Long dailyRoomRateAmount, - Delivery delivery, - List extraCharges, - Map extraParams, - Boolean fireSafetyActCompliance, - Object name, - Boolean noShow, - Long numberOfRooms, - List passengers, - Object propertyPhoneNumber, - Object roomClass, - Long roomNights, - Long totalRoomTaxAmount, - Long totalTaxAmount) { - this.address = address; - this.adults = adults; - this.affiliate = affiliate; - this.bookingNumber = bookingNumber; - this.category = category; - this.checkinAt = checkinAt; - this.checkoutAt = checkoutAt; - this.customerServicePhoneNumber = customerServicePhoneNumber; - this.dailyRoomRateAmount = dailyRoomRateAmount; - this.delivery = delivery; - this.extraCharges = extraCharges; - this.extraParams = extraParams; - this.fireSafetyActCompliance = fireSafetyActCompliance; - this.name = name; - this.noShow = noShow; - this.numberOfRooms = numberOfRooms; - this.passengers = passengers; - this.propertyPhoneNumber = propertyPhoneNumber; - this.roomClass = roomClass; - this.roomNights = roomNights; - this.totalRoomTaxAmount = totalRoomTaxAmount; - this.totalTaxAmount = totalTaxAmount; - } + /** + * Add an element to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.Lodging#passengers} for the field documentation. + */ + public Builder addPassenger( + PaymentIntentUpdateParams.PaymentDetails.Lodging.Passenger element) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.add(element); + return this; + } - public static Builder builder() { - return new Builder(); - } + /** + * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.Lodging#passengers} for the field documentation. + */ + public Builder addAllPassenger( + List elements) { + if (this.passengers == null) { + this.passengers = new ArrayList<>(); + } + this.passengers.addAll(elements); + return this; + } - public static class Builder { - private Address address; + /** The phone number of the lodging location. */ + public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { + this.propertyPhoneNumber = propertyPhoneNumber; + return this; + } - private Long adults; + /** The phone number of the lodging location. */ + public Builder setPropertyPhoneNumber(EmptyParam propertyPhoneNumber) { + this.propertyPhoneNumber = propertyPhoneNumber; + return this; + } - private Affiliate affiliate; + /** The room class for this purchase. */ + public Builder setRoomClass(String roomClass) { + this.roomClass = roomClass; + return this; + } - private Object bookingNumber; + /** The room class for this purchase. */ + public Builder setRoomClass(EmptyParam roomClass) { + this.roomClass = roomClass; + return this; + } - private Category category; + /** The number of room nights. */ + public Builder setRoomNights(Long roomNights) { + this.roomNights = roomNights; + return this; + } - private Long checkinAt; + /** The total tax amount associating with the room reservation. */ + public Builder setTotalRoomTaxAmount(Long totalRoomTaxAmount) { + this.totalRoomTaxAmount = totalRoomTaxAmount; + return this; + } - private Long checkoutAt; + /** The total tax amount. */ + public Builder setTotalTaxAmount(Long totalTaxAmount) { + this.totalTaxAmount = totalTaxAmount; + return this; + } + } - private Object customerServicePhoneNumber; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Address { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + Object city; - private Long dailyRoomRateAmount; + /** + * Two-letter country code (ISO + * 3166-1 alpha-2). + */ + @SerializedName("country") + Object country; - private Delivery delivery; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private List extraCharges; + /** Address line 1, such as the street, PO Box, or company name. */ + @SerializedName("line1") + Object line1; - private Map extraParams; + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + Object line2; - private Boolean fireSafetyActCompliance; + /** ZIP or postal code. */ + @SerializedName("postal_code") + Object postalCode; - private Object name; + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + Object state; - private Boolean noShow; + private Address( + Object city, + Object country, + Map extraParams, + Object line1, + Object line2, + Object postalCode, + Object state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } - private Long numberOfRooms; + public static Builder builder() { + return new Builder(); + } - private List passengers; + public static class Builder { + private Object city; - private Object propertyPhoneNumber; + private Object country; - private Object roomClass; + private Map extraParams; - private Long roomNights; + private Object line1; - private Long totalRoomTaxAmount; + private Object line2; - private Long totalTaxAmount; + private Object postalCode; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.Lodging build() { - return new PaymentIntentUpdateParams.PaymentDetails.Lodging( - this.address, - this.adults, - this.affiliate, - this.bookingNumber, - this.category, - this.checkinAt, - this.checkoutAt, - this.customerServicePhoneNumber, - this.dailyRoomRateAmount, - this.delivery, - this.extraCharges, - this.extraParams, - this.fireSafetyActCompliance, - this.name, - this.noShow, - this.numberOfRooms, - this.passengers, - this.propertyPhoneNumber, - this.roomClass, - this.roomNights, - this.totalRoomTaxAmount, - this.totalTaxAmount); - } + private Object state; - /** The lodging location's address. */ - public Builder setAddress( - PaymentIntentUpdateParams.PaymentDetails.Lodging.Address address) { - this.address = address; - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.Lodging.Address build() { + return new PaymentIntentUpdateParams.PaymentDetails.Lodging.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } - /** The number of adults on the booking. */ - public Builder setAdults(Long adults) { - this.adults = adults; - return this; - } + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } - /** Affiliate details for this purchase. */ - public Builder setAffiliate( - PaymentIntentUpdateParams.PaymentDetails.Lodging.Affiliate affiliate) { - this.affiliate = affiliate; - return this; - } + /** City, district, suburb, town, or village. */ + public Builder setCity(EmptyParam city) { + this.city = city; + return this; + } - /** The booking number associated with the lodging reservation. */ - public Builder setBookingNumber(String bookingNumber) { - this.bookingNumber = bookingNumber; - return this; - } + /** + * Two-letter country code (ISO + * 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } - /** The booking number associated with the lodging reservation. */ - public Builder setBookingNumber(EmptyParam bookingNumber) { - this.bookingNumber = bookingNumber; - return this; - } + /** + * Two-letter country code (ISO + * 3166-1 alpha-2). + */ + public Builder setCountry(EmptyParam country) { + this.country = country; + return this; + } - /** The lodging category. */ - public Builder setCategory( - PaymentIntentUpdateParams.PaymentDetails.Lodging.Category category) { - this.category = category; - return this; - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging.Address#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** - * Required. Lodging check-in time. Measured in seconds since the Unix - * epoch. - */ - public Builder setCheckinAt(Long checkinAt) { - this.checkinAt = checkinAt; - return this; - } + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging.Address#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** - * Required. Lodging check-out time. Measured in seconds since the Unix - * epoch. - */ - public Builder setCheckoutAt(Long checkoutAt) { - this.checkoutAt = checkoutAt; - return this; - } + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } - /** The customer service phone number of the lodging company. */ - public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { - this.customerServicePhoneNumber = customerServicePhoneNumber; - return this; - } + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(EmptyParam line1) { + this.line1 = line1; + return this; + } - /** The customer service phone number of the lodging company. */ - public Builder setCustomerServicePhoneNumber(EmptyParam customerServicePhoneNumber) { - this.customerServicePhoneNumber = customerServicePhoneNumber; - return this; - } + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } - /** The daily lodging room rate. */ - public Builder setDailyRoomRateAmount(Long dailyRoomRateAmount) { - this.dailyRoomRateAmount = dailyRoomRateAmount; - return this; - } + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(EmptyParam line2) { + this.line2 = line2; + return this; + } - /** Delivery details for this purchase. */ - public Builder setDelivery( - PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery delivery) { - this.delivery = delivery; - return this; - } + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - /** - * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.Lodging#extraCharges} for the field - * documentation. - */ - public Builder addExtraCharge( - PaymentIntentUpdateParams.PaymentDetails.Lodging.ExtraCharge element) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); + /** ZIP or postal code. */ + public Builder setPostalCode(EmptyParam postalCode) { + this.postalCode = postalCode; + return this; } - this.extraCharges.add(element); - return this; - } - /** - * Add all elements to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.Lodging#extraCharges} for the field - * documentation. - */ - public Builder addAllExtraCharge( - List elements) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; } - this.extraCharges.addAll(elements); - return this; - } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(EmptyParam state) { + this.state = state; + return this; } - this.extraParams.put(key, value); - return this; } + } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Affiliate { /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging#extraParams} for the - * field documentation. + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Indicates whether the lodging location is compliant with the Fire Safety Act. */ - public Builder setFireSafetyActCompliance(Boolean fireSafetyActCompliance) { - this.fireSafetyActCompliance = fireSafetyActCompliance; - return this; - } + /** Required. The name of the affiliate that originated the purchase. */ + @SerializedName("name") + Object name; - /** The name of the lodging location. */ - public Builder setName(String name) { + private Affiliate(Map extraParams, Object name) { + this.extraParams = extraParams; this.name = name; - return this; } - /** The name of the lodging location. */ - public Builder setName(EmptyParam name) { - this.name = name; - return this; + public static Builder builder() { + return new Builder(); } - /** - * Indicates if the customer did not keep their booking while failing to cancel the - * reservation. - */ - public Builder setNoShow(Boolean noShow) { - this.noShow = noShow; - return this; - } + public static class Builder { + private Map extraParams; - /** The number of rooms on the booking. */ - public Builder setNumberOfRooms(Long numberOfRooms) { - this.numberOfRooms = numberOfRooms; - return this; - } + private Object name; - /** - * Add an element to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.Lodging#passengers} for the field documentation. - */ - public Builder addPassenger( - PaymentIntentUpdateParams.PaymentDetails.Lodging.Passenger element) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.Lodging.Affiliate build() { + return new PaymentIntentUpdateParams.PaymentDetails.Lodging.Affiliate( + this.extraParams, this.name); } - this.passengers.add(element); - return this; - } - /** - * Add all elements to `passengers` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.Lodging#passengers} for the field documentation. - */ - public Builder addAllPassenger( - List elements) { - if (this.passengers == null) { - this.passengers = new ArrayList<>(); + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging.Affiliate#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; } - this.passengers.addAll(elements); - return this; - } - - /** The phone number of the lodging location. */ - public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { - this.propertyPhoneNumber = propertyPhoneNumber; - return this; - } - - /** The phone number of the lodging location. */ - public Builder setPropertyPhoneNumber(EmptyParam propertyPhoneNumber) { - this.propertyPhoneNumber = propertyPhoneNumber; - return this; - } - - /** The room class for this purchase. */ - public Builder setRoomClass(String roomClass) { - this.roomClass = roomClass; - return this; - } - - /** The room class for this purchase. */ - public Builder setRoomClass(EmptyParam roomClass) { - this.roomClass = roomClass; - return this; - } - /** The number of room nights. */ - public Builder setRoomNights(Long roomNights) { - this.roomNights = roomNights; - return this; - } + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging.Affiliate#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** The total tax amount associating with the room reservation. */ - public Builder setTotalRoomTaxAmount(Long totalRoomTaxAmount) { - this.totalRoomTaxAmount = totalRoomTaxAmount; - return this; - } + /** Required. The name of the affiliate that originated the purchase. */ + public Builder setName(String name) { + this.name = name; + return this; + } - /** The total tax amount. */ - public Builder setTotalTaxAmount(Long totalTaxAmount) { - this.totalTaxAmount = totalTaxAmount; - return this; + /** Required. The name of the affiliate that originated the purchase. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Address { - /** City, district, suburb, town, or village. */ - @SerializedName("city") - Object city; - - /** - * Two-letter country code (ISO - * 3166-1 alpha-2). - */ - @SerializedName("country") - Object country; - + public static class Delivery { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -12003,40 +13701,18 @@ public static class Address { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Address line 1, such as the street, PO Box, or company name. */ - @SerializedName("line1") - Object line1; - - /** Address line 2, such as the apartment, suite, unit, or building. */ - @SerializedName("line2") - Object line2; - - /** ZIP or postal code. */ - @SerializedName("postal_code") - Object postalCode; + /** The delivery method for the payment. */ + @SerializedName("mode") + Mode mode; - /** - * State, county, province, or region (ISO 3166-2). - */ - @SerializedName("state") - Object state; + /** Details of the recipient. */ + @SerializedName("recipient") + Recipient recipient; - private Address( - Object city, - Object country, - Map extraParams, - Object line1, - Object line2, - Object postalCode, - Object state) { - this.city = city; - this.country = country; + private Delivery(Map extraParams, Mode mode, Recipient recipient) { this.extraParams = extraParams; - this.line1 = line1; - this.line2 = line2; - this.postalCode = postalCode; - this.state = state; + this.mode = mode; + this.recipient = recipient; } public static Builder builder() { @@ -12044,66 +13720,22 @@ public static Builder builder() { } public static class Builder { - private Object city; - - private Object country; - private Map extraParams; - private Object line1; - - private Object line2; - - private Object postalCode; + private Mode mode; - private Object state; + private Recipient recipient; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.Lodging.Address build() { - return new PaymentIntentUpdateParams.PaymentDetails.Lodging.Address( - this.city, - this.country, - this.extraParams, - this.line1, - this.line2, - this.postalCode, - this.state); - } - - /** City, district, suburb, town, or village. */ - public Builder setCity(String city) { - this.city = city; - return this; - } - - /** City, district, suburb, town, or village. */ - public Builder setCity(EmptyParam city) { - this.city = city; - return this; - } - - /** - * Two-letter country code (ISO - * 3166-1 alpha-2). - */ - public Builder setCountry(String country) { - this.country = country; - return this; - } - - /** - * Two-letter country code (ISO - * 3166-1 alpha-2). - */ - public Builder setCountry(EmptyParam country) { - this.country = country; - return this; + public PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery build() { + return new PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery( + this.extraParams, this.mode, this.recipient); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging.Address#extraParams} + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery#extraParams} * for the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -12117,7 +13749,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging.Address#extraParams} + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery#extraParams} * for the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -12128,65 +13760,166 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Address line 1, such as the street, PO Box, or company name. */ - public Builder setLine1(String line1) { - this.line1 = line1; + /** The delivery method for the payment. */ + public Builder setMode( + PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery.Mode mode) { + this.mode = mode; + return this; + } + + /** Details of the recipient. */ + public Builder setRecipient( + PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery.Recipient recipient) { + this.recipient = recipient; return this; } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Recipient { + /** The email of the recipient the ticket is delivered to. */ + @SerializedName("email") + Object email; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The name of the recipient the ticket is delivered to. */ + @SerializedName("name") + Object name; + + /** The phone number of the recipient the ticket is delivered to. */ + @SerializedName("phone") + Object phone; + + private Recipient( + Object email, Map extraParams, Object name, Object phone) { + this.email = email; + this.extraParams = extraParams; + this.name = name; + this.phone = phone; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object email; + + private Map extraParams; + + private Object name; + + private Object phone; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery.Recipient build() { + return new PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery.Recipient( + this.email, this.extraParams, this.name, this.phone); + } + + /** The email of the recipient the ticket is delivered to. */ + public Builder setEmail(String email) { + this.email = email; + return this; + } + + /** The email of the recipient the ticket is delivered to. */ + public Builder setEmail(EmptyParam email) { + this.email = email; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The name of the recipient the ticket is delivered to. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** The name of the recipient the ticket is delivered to. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } + + /** The phone number of the recipient the ticket is delivered to. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } - /** Address line 1, such as the street, PO Box, or company name. */ - public Builder setLine1(EmptyParam line1) { - this.line1 = line1; - return this; + /** The phone number of the recipient the ticket is delivered to. */ + public Builder setPhone(EmptyParam phone) { + this.phone = phone; + return this; + } } + } - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(String line2) { - this.line2 = line2; - return this; - } + public enum Mode implements ApiRequestParams.EnumParam { + @SerializedName("email") + EMAIL("email"), - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(EmptyParam line2) { - this.line2 = line2; - return this; - } + @SerializedName("phone") + PHONE("phone"), - /** ZIP or postal code. */ - public Builder setPostalCode(String postalCode) { - this.postalCode = postalCode; - return this; - } + @SerializedName("pickup") + PICKUP("pickup"), - /** ZIP or postal code. */ - public Builder setPostalCode(EmptyParam postalCode) { - this.postalCode = postalCode; - return this; - } + @SerializedName("post") + POST("post"); - /** - * State, county, province, or region (ISO 3166-2). - */ - public Builder setState(String state) { - this.state = state; - return this; - } + @Getter(onMethod_ = {@Override}) + private final String value; - /** - * State, county, province, or region (ISO 3166-2). - */ - public Builder setState(EmptyParam state) { - this.state = state; - return this; + Mode(String value) { + this.value = value; } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Affiliate { + public static class Passenger { /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -12197,11 +13930,13 @@ public static class Affiliate { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Required. The name of the affiliate that originated the purchase. */ + /** + * Required. Full name of the person or entity on the lodging reservation. + */ @SerializedName("name") Object name; - private Affiliate(Map extraParams, Object name) { + private Passenger(Map extraParams, Object name) { this.extraParams = extraParams; this.name = name; } @@ -12216,15 +13951,15 @@ public static class Builder { private Object name; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.Lodging.Affiliate build() { - return new PaymentIntentUpdateParams.PaymentDetails.Lodging.Affiliate( + public PaymentIntentUpdateParams.PaymentDetails.Lodging.Passenger build() { + return new PaymentIntentUpdateParams.PaymentDetails.Lodging.Passenger( this.extraParams, this.name); } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging.Affiliate#extraParams} + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging.Passenger#extraParams} * for the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -12238,7 +13973,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging.Affiliate#extraParams} + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging.Passenger#extraParams} * for the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -12249,13 +13984,19 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Required. The name of the affiliate that originated the purchase. */ + /** + * Required. Full name of the person or entity on the lodging + * reservation. + */ public Builder setName(String name) { this.name = name; return this; } - /** Required. The name of the affiliate that originated the purchase. */ + /** + * Required. Full name of the person or entity on the lodging + * reservation. + */ public Builder setName(EmptyParam name) { this.name = name; return this; @@ -12263,721 +14004,795 @@ public Builder setName(EmptyParam name) { } } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Delivery { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public enum Category implements ApiRequestParams.EnumParam { + @SerializedName("hotel") + HOTEL("hotel"), - /** The delivery method for the payment. */ - @SerializedName("mode") - Mode mode; + @SerializedName("vacation_rental") + VACATION_RENTAL("vacation_rental"); - /** Details of the recipient. */ - @SerializedName("recipient") - Recipient recipient; + @Getter(onMethod_ = {@Override}) + private final String value; - private Delivery(Map extraParams, Mode mode, Recipient recipient) { - this.extraParams = extraParams; - this.mode = mode; - this.recipient = recipient; + Category(String value) { + this.value = value; } + } - public static Builder builder() { - return new Builder(); + public enum ExtraCharge implements ApiRequestParams.EnumParam { + @SerializedName("gift_shop") + GIFT_SHOP("gift_shop"), + + @SerializedName("laundry") + LAUNDRY("laundry"), + + @SerializedName("mini_bar") + MINI_BAR("mini_bar"), + + @SerializedName("other") + OTHER("other"), + + @SerializedName("restaurant") + RESTAURANT("restaurant"), + + @SerializedName("telephone") + TELEPHONE("telephone"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ExtraCharge(String value) { + this.value = value; } + } + } - public static class Builder { - private Map extraParams; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class LodgingData { + /** Accommodation details for the lodging. */ + @SerializedName("accommodation") + Accommodation accommodation; - private Mode mode; + /** Affiliate details if applicable. */ + @SerializedName("affiliate") + Affiliate affiliate; - private Recipient recipient; + /** Booking confirmation number for the lodging. */ + @SerializedName("booking_number") + Object bookingNumber; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery build() { - return new PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery( - this.extraParams, this.mode, this.recipient); - } + /** Required. Check-in date. */ + @SerializedName("checkin_at") + Long checkinAt; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** Required. Check-out date. */ + @SerializedName("checkout_at") + Long checkoutAt; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** Customer service phone number for the lodging company. */ + @SerializedName("customer_service_phone_number") + Object customerServicePhoneNumber; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Whether the lodging is compliant with any hotel fire safety regulations. */ + @SerializedName("fire_safety_act_compliance_indicator") + Boolean fireSafetyActComplianceIndicator; + + /** List of guests for the lodging. */ + @SerializedName("guests") + List guests; + + /** Host details for the lodging. */ + @SerializedName("host") + Host host; + + /** List of insurances for the lodging. */ + @SerializedName("insurances") + List insurances; + + /** Whether the renter is a no-show. */ + @SerializedName("no_show_indicator") + Boolean noShowIndicator; + + /** Renter ID number for the lodging. */ + @SerializedName("renter_id_number") + Object renterIdNumber; + + /** Renter name for the lodging. */ + @SerializedName("renter_name") + Object renterName; + + /** Required. Total details for the lodging. */ + @SerializedName("total") + Total total; + + private LodgingData( + Accommodation accommodation, + Affiliate affiliate, + Object bookingNumber, + Long checkinAt, + Long checkoutAt, + Object customerServicePhoneNumber, + Map extraParams, + Boolean fireSafetyActComplianceIndicator, + List guests, + Host host, + List insurances, + Boolean noShowIndicator, + Object renterIdNumber, + Object renterName, + Total total) { + this.accommodation = accommodation; + this.affiliate = affiliate; + this.bookingNumber = bookingNumber; + this.checkinAt = checkinAt; + this.checkoutAt = checkoutAt; + this.customerServicePhoneNumber = customerServicePhoneNumber; + this.extraParams = extraParams; + this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; + this.guests = guests; + this.host = host; + this.insurances = insurances; + this.noShowIndicator = noShowIndicator; + this.renterIdNumber = renterIdNumber; + this.renterName = renterName; + this.total = total; + } - /** The delivery method for the payment. */ - public Builder setMode( - PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery.Mode mode) { - this.mode = mode; - return this; - } + public static Builder builder() { + return new Builder(); + } - /** Details of the recipient. */ - public Builder setRecipient( - PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery.Recipient recipient) { - this.recipient = recipient; - return this; - } - } + public static class Builder { + private Accommodation accommodation; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Recipient { - /** The email of the recipient the ticket is delivered to. */ - @SerializedName("email") - Object email; + private Affiliate affiliate; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private Object bookingNumber; - /** The name of the recipient the ticket is delivered to. */ - @SerializedName("name") - Object name; + private Long checkinAt; - /** The phone number of the recipient the ticket is delivered to. */ - @SerializedName("phone") - Object phone; + private Long checkoutAt; - private Recipient( - Object email, Map extraParams, Object name, Object phone) { - this.email = email; - this.extraParams = extraParams; - this.name = name; - this.phone = phone; - } + private Object customerServicePhoneNumber; - public static Builder builder() { - return new Builder(); - } + private Map extraParams; - public static class Builder { - private Object email; + private Boolean fireSafetyActComplianceIndicator; - private Map extraParams; + private List guests; - private Object name; + private Host host; - private Object phone; + private List insurances; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery.Recipient build() { - return new PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery.Recipient( - this.email, this.extraParams, this.name, this.phone); - } + private Boolean noShowIndicator; - /** The email of the recipient the ticket is delivered to. */ - public Builder setEmail(String email) { - this.email = email; - return this; - } + private Object renterIdNumber; - /** The email of the recipient the ticket is delivered to. */ - public Builder setEmail(EmptyParam email) { - this.email = email; - return this; - } + private Object renterName; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + private Total total; - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.Lodging.Delivery.Recipient#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.LodgingData build() { + return new PaymentIntentUpdateParams.PaymentDetails.LodgingData( + this.accommodation, + this.affiliate, + this.bookingNumber, + this.checkinAt, + this.checkoutAt, + this.customerServicePhoneNumber, + this.extraParams, + this.fireSafetyActComplianceIndicator, + this.guests, + this.host, + this.insurances, + this.noShowIndicator, + this.renterIdNumber, + this.renterName, + this.total); + } - /** The name of the recipient the ticket is delivered to. */ - public Builder setName(String name) { - this.name = name; - return this; - } + /** Accommodation details for the lodging. */ + public Builder setAccommodation( + PaymentIntentUpdateParams.PaymentDetails.LodgingData.Accommodation accommodation) { + this.accommodation = accommodation; + return this; + } - /** The name of the recipient the ticket is delivered to. */ - public Builder setName(EmptyParam name) { - this.name = name; - return this; - } + /** Affiliate details if applicable. */ + public Builder setAffiliate( + PaymentIntentUpdateParams.PaymentDetails.LodgingData.Affiliate affiliate) { + this.affiliate = affiliate; + return this; + } - /** The phone number of the recipient the ticket is delivered to. */ - public Builder setPhone(String phone) { - this.phone = phone; - return this; - } + /** Booking confirmation number for the lodging. */ + public Builder setBookingNumber(String bookingNumber) { + this.bookingNumber = bookingNumber; + return this; + } - /** The phone number of the recipient the ticket is delivered to. */ - public Builder setPhone(EmptyParam phone) { - this.phone = phone; - return this; - } - } + /** Booking confirmation number for the lodging. */ + public Builder setBookingNumber(EmptyParam bookingNumber) { + this.bookingNumber = bookingNumber; + return this; } - public enum Mode implements ApiRequestParams.EnumParam { - @SerializedName("email") - EMAIL("email"), + /** Required. Check-in date. */ + public Builder setCheckinAt(Long checkinAt) { + this.checkinAt = checkinAt; + return this; + } - @SerializedName("phone") - PHONE("phone"), + /** Required. Check-out date. */ + public Builder setCheckoutAt(Long checkoutAt) { + this.checkoutAt = checkoutAt; + return this; + } - @SerializedName("pickup") - PICKUP("pickup"), + /** Customer service phone number for the lodging company. */ + public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; + } - @SerializedName("post") - POST("post"); + /** Customer service phone number for the lodging company. */ + public Builder setCustomerServicePhoneNumber(EmptyParam customerServicePhoneNumber) { + this.customerServicePhoneNumber = customerServicePhoneNumber; + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - Mode(String value) { - this.value = value; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); } + this.extraParams.putAll(map); + return this; + } + + /** Whether the lodging is compliant with any hotel fire safety regulations. */ + public Builder setFireSafetyActComplianceIndicator( + Boolean fireSafetyActComplianceIndicator) { + this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; + return this; } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Passenger { /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. + * Add an element to `guests` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData#guests} for the field documentation. */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public Builder addGuest( + PaymentIntentUpdateParams.PaymentDetails.LodgingData.Guest element) { + if (this.guests == null) { + this.guests = new ArrayList<>(); + } + this.guests.add(element); + return this; + } /** - * Required. Full name of the person or entity on the lodging reservation. + * Add all elements to `guests` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData#guests} for the field documentation. */ - @SerializedName("name") - Object name; - - private Passenger(Map extraParams, Object name) { - this.extraParams = extraParams; - this.name = name; + public Builder addAllGuest( + List elements) { + if (this.guests == null) { + this.guests = new ArrayList<>(); + } + this.guests.addAll(elements); + return this; } - public static Builder builder() { - return new Builder(); + /** Host details for the lodging. */ + public Builder setHost(PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host host) { + this.host = host; + return this; } - public static class Builder { - private Map extraParams; - - private Object name; - - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.Lodging.Passenger build() { - return new PaymentIntentUpdateParams.PaymentDetails.Lodging.Passenger( - this.extraParams, this.name); - } - - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging.Passenger#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; + /** + * Add an element to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData#insurances} for the field + * documentation. + */ + public Builder addInsurance( + PaymentIntentUpdateParams.PaymentDetails.LodgingData.Insurance element) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); } + this.insurances.add(element); + return this; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.Lodging.Passenger#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; + /** + * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData#insurances} for the field + * documentation. + */ + public Builder addAllInsurance( + List elements) { + if (this.insurances == null) { + this.insurances = new ArrayList<>(); } + this.insurances.addAll(elements); + return this; + } - /** - * Required. Full name of the person or entity on the lodging - * reservation. - */ - public Builder setName(String name) { - this.name = name; - return this; - } + /** Whether the renter is a no-show. */ + public Builder setNoShowIndicator(Boolean noShowIndicator) { + this.noShowIndicator = noShowIndicator; + return this; + } - /** - * Required. Full name of the person or entity on the lodging - * reservation. - */ - public Builder setName(EmptyParam name) { - this.name = name; - return this; - } + /** Renter ID number for the lodging. */ + public Builder setRenterIdNumber(String renterIdNumber) { + this.renterIdNumber = renterIdNumber; + return this; } - } - public enum Category implements ApiRequestParams.EnumParam { - @SerializedName("hotel") - HOTEL("hotel"), + /** Renter ID number for the lodging. */ + public Builder setRenterIdNumber(EmptyParam renterIdNumber) { + this.renterIdNumber = renterIdNumber; + return this; + } - @SerializedName("vacation_rental") - VACATION_RENTAL("vacation_rental"); + /** Renter name for the lodging. */ + public Builder setRenterName(String renterName) { + this.renterName = renterName; + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** Renter name for the lodging. */ + public Builder setRenterName(EmptyParam renterName) { + this.renterName = renterName; + return this; + } - Category(String value) { - this.value = value; + /** Required. Total details for the lodging. */ + public Builder setTotal(PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total total) { + this.total = total; + return this; } } - public enum ExtraCharge implements ApiRequestParams.EnumParam { - @SerializedName("gift_shop") - GIFT_SHOP("gift_shop"), - - @SerializedName("laundry") - LAUNDRY("laundry"), - - @SerializedName("mini_bar") - MINI_BAR("mini_bar"), + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Accommodation { + /** Type of accommodation. */ + @SerializedName("accommodation_type") + AccommodationType accommodationType; - @SerializedName("other") - OTHER("other"), + /** Bed type. */ + @SerializedName("bed_type") + Object bedType; - @SerializedName("restaurant") - RESTAURANT("restaurant"), + /** Daily accommodation rate in cents. */ + @SerializedName("daily_rate_amount") + Long dailyRateAmount; - @SerializedName("telephone") - TELEPHONE("telephone"); + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - @Getter(onMethod_ = {@Override}) - private final String value; + /** Number of nights. */ + @SerializedName("nights") + Long nights; - ExtraCharge(String value) { - this.value = value; - } - } - } + /** Number of rooms, cabanas, apartments, and so on. */ + @SerializedName("number_of_rooms") + Long numberOfRooms; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class LodgingData { - /** Accommodation details for the lodging. */ - @SerializedName("accommodation") - Accommodation accommodation; + /** Rate type. */ + @SerializedName("rate_type") + Object rateType; - /** Affiliate details if applicable. */ - @SerializedName("affiliate") - Affiliate affiliate; + /** Whether smoking is allowed. */ + @SerializedName("smoking_indicator") + Boolean smokingIndicator; - /** Booking confirmation number for the lodging. */ - @SerializedName("booking_number") - Object bookingNumber; + private Accommodation( + AccommodationType accommodationType, + Object bedType, + Long dailyRateAmount, + Map extraParams, + Long nights, + Long numberOfRooms, + Object rateType, + Boolean smokingIndicator) { + this.accommodationType = accommodationType; + this.bedType = bedType; + this.dailyRateAmount = dailyRateAmount; + this.extraParams = extraParams; + this.nights = nights; + this.numberOfRooms = numberOfRooms; + this.rateType = rateType; + this.smokingIndicator = smokingIndicator; + } - /** Required. Check-in date. */ - @SerializedName("checkin_at") - Long checkinAt; + public static Builder builder() { + return new Builder(); + } - /** Required. Check-out date. */ - @SerializedName("checkout_at") - Long checkoutAt; + public static class Builder { + private AccommodationType accommodationType; - /** Customer service phone number for the lodging company. */ - @SerializedName("customer_service_phone_number") - Object customerServicePhoneNumber; + private Object bedType; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) - * name in this param object. Effectively, this map is flattened to its parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private Long dailyRateAmount; - /** Whether the lodging is compliant with any hotel fire safety regulations. */ - @SerializedName("fire_safety_act_compliance_indicator") - Boolean fireSafetyActComplianceIndicator; + private Map extraParams; - /** List of guests for the lodging. */ - @SerializedName("guests") - List guests; + private Long nights; - /** Host details for the lodging. */ - @SerializedName("host") - Host host; + private Long numberOfRooms; - /** List of insurances for the lodging. */ - @SerializedName("insurances") - List insurances; + private Object rateType; - /** Whether the renter is a no-show. */ - @SerializedName("no_show_indicator") - Boolean noShowIndicator; + private Boolean smokingIndicator; - /** Renter ID number for the lodging. */ - @SerializedName("renter_id_number") - Object renterIdNumber; + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Accommodation build() { + return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Accommodation( + this.accommodationType, + this.bedType, + this.dailyRateAmount, + this.extraParams, + this.nights, + this.numberOfRooms, + this.rateType, + this.smokingIndicator); + } - /** Renter name for the lodging. */ - @SerializedName("renter_name") - Object renterName; + /** Type of accommodation. */ + public Builder setAccommodationType( + PaymentIntentUpdateParams.PaymentDetails.LodgingData.Accommodation.AccommodationType + accommodationType) { + this.accommodationType = accommodationType; + return this; + } - /** Required. Total details for the lodging. */ - @SerializedName("total") - Total total; + /** Bed type. */ + public Builder setBedType(String bedType) { + this.bedType = bedType; + return this; + } - private LodgingData( - Accommodation accommodation, - Affiliate affiliate, - Object bookingNumber, - Long checkinAt, - Long checkoutAt, - Object customerServicePhoneNumber, - Map extraParams, - Boolean fireSafetyActComplianceIndicator, - List guests, - Host host, - List insurances, - Boolean noShowIndicator, - Object renterIdNumber, - Object renterName, - Total total) { - this.accommodation = accommodation; - this.affiliate = affiliate; - this.bookingNumber = bookingNumber; - this.checkinAt = checkinAt; - this.checkoutAt = checkoutAt; - this.customerServicePhoneNumber = customerServicePhoneNumber; - this.extraParams = extraParams; - this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; - this.guests = guests; - this.host = host; - this.insurances = insurances; - this.noShowIndicator = noShowIndicator; - this.renterIdNumber = renterIdNumber; - this.renterName = renterName; - this.total = total; - } + /** Bed type. */ + public Builder setBedType(EmptyParam bedType) { + this.bedType = bedType; + return this; + } - public static Builder builder() { - return new Builder(); - } + /** Daily accommodation rate in cents. */ + public Builder setDailyRateAmount(Long dailyRateAmount) { + this.dailyRateAmount = dailyRateAmount; + return this; + } - public static class Builder { - private Accommodation accommodation; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Accommodation#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - private Affiliate affiliate; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Accommodation#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - private Object bookingNumber; + /** Number of nights. */ + public Builder setNights(Long nights) { + this.nights = nights; + return this; + } - private Long checkinAt; + /** Number of rooms, cabanas, apartments, and so on. */ + public Builder setNumberOfRooms(Long numberOfRooms) { + this.numberOfRooms = numberOfRooms; + return this; + } - private Long checkoutAt; + /** Rate type. */ + public Builder setRateType(String rateType) { + this.rateType = rateType; + return this; + } - private Object customerServicePhoneNumber; + /** Rate type. */ + public Builder setRateType(EmptyParam rateType) { + this.rateType = rateType; + return this; + } - private Map extraParams; + /** Whether smoking is allowed. */ + public Builder setSmokingIndicator(Boolean smokingIndicator) { + this.smokingIndicator = smokingIndicator; + return this; + } + } - private Boolean fireSafetyActComplianceIndicator; + public enum AccommodationType implements ApiRequestParams.EnumParam { + @SerializedName("apartment") + APARTMENT("apartment"), - private List guests; + @SerializedName("cabana") + CABANA("cabana"), - private Host host; + @SerializedName("house") + HOUSE("house"), - private List insurances; + @SerializedName("penthouse") + PENTHOUSE("penthouse"), - private Boolean noShowIndicator; + @SerializedName("room") + ROOM("room"), - private Object renterIdNumber; + @SerializedName("standard") + STANDARD("standard"), - private Object renterName; + @SerializedName("suite") + SUITE("suite"), - private Total total; + @SerializedName("villa") + VILLA("villa"); - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.LodgingData build() { - return new PaymentIntentUpdateParams.PaymentDetails.LodgingData( - this.accommodation, - this.affiliate, - this.bookingNumber, - this.checkinAt, - this.checkoutAt, - this.customerServicePhoneNumber, - this.extraParams, - this.fireSafetyActComplianceIndicator, - this.guests, - this.host, - this.insurances, - this.noShowIndicator, - this.renterIdNumber, - this.renterName, - this.total); - } + @Getter(onMethod_ = {@Override}) + private final String value; - /** Accommodation details for the lodging. */ - public Builder setAccommodation( - PaymentIntentUpdateParams.PaymentDetails.LodgingData.Accommodation accommodation) { - this.accommodation = accommodation; - return this; + AccommodationType(String value) { + this.value = value; + } } + } - /** Affiliate details if applicable. */ - public Builder setAffiliate( - PaymentIntentUpdateParams.PaymentDetails.LodgingData.Affiliate affiliate) { - this.affiliate = affiliate; - return this; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Affiliate { + /** Affiliate partner code. */ + @SerializedName("code") + Object code; - /** Booking confirmation number for the lodging. */ - public Builder setBookingNumber(String bookingNumber) { - this.bookingNumber = bookingNumber; - return this; - } + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Affiliate partner name. */ + @SerializedName("name") + Object name; - /** Booking confirmation number for the lodging. */ - public Builder setBookingNumber(EmptyParam bookingNumber) { - this.bookingNumber = bookingNumber; - return this; + private Affiliate(Object code, Map extraParams, Object name) { + this.code = code; + this.extraParams = extraParams; + this.name = name; } - /** Required. Check-in date. */ - public Builder setCheckinAt(Long checkinAt) { - this.checkinAt = checkinAt; - return this; + public static Builder builder() { + return new Builder(); } - /** Required. Check-out date. */ - public Builder setCheckoutAt(Long checkoutAt) { - this.checkoutAt = checkoutAt; - return this; - } + public static class Builder { + private Object code; - /** Customer service phone number for the lodging company. */ - public Builder setCustomerServicePhoneNumber(String customerServicePhoneNumber) { - this.customerServicePhoneNumber = customerServicePhoneNumber; - return this; - } + private Map extraParams; - /** Customer service phone number for the lodging company. */ - public Builder setCustomerServicePhoneNumber(EmptyParam customerServicePhoneNumber) { - this.customerServicePhoneNumber = customerServicePhoneNumber; - return this; - } + private Object name; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Affiliate build() { + return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Affiliate( + this.code, this.extraParams, this.name); } - this.extraParams.put(key, value); - return this; - } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** Affiliate partner code. */ + public Builder setCode(String code) { + this.code = code; + return this; } - this.extraParams.putAll(map); - return this; - } - /** Whether the lodging is compliant with any hotel fire safety regulations. */ - public Builder setFireSafetyActComplianceIndicator( - Boolean fireSafetyActComplianceIndicator) { - this.fireSafetyActComplianceIndicator = fireSafetyActComplianceIndicator; - return this; - } + /** Affiliate partner code. */ + public Builder setCode(EmptyParam code) { + this.code = code; + return this; + } - /** - * Add an element to `guests` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData#guests} for the field documentation. - */ - public Builder addGuest( - PaymentIntentUpdateParams.PaymentDetails.LodgingData.Guest element) { - if (this.guests == null) { - this.guests = new ArrayList<>(); + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; } - this.guests.add(element); - return this; - } - /** - * Add all elements to `guests` list. A list is initialized for the first `add/addAll` call, - * and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData#guests} for the field documentation. - */ - public Builder addAllGuest( - List elements) { - if (this.guests == null) { - this.guests = new ArrayList<>(); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Affiliate#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; } - this.guests.addAll(elements); - return this; - } - /** Host details for the lodging. */ - public Builder setHost(PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host host) { - this.host = host; - return this; - } + /** Affiliate partner name. */ + public Builder setName(String name) { + this.name = name; + return this; + } - /** - * Add an element to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData#insurances} for the field - * documentation. - */ - public Builder addInsurance( - PaymentIntentUpdateParams.PaymentDetails.LodgingData.Insurance element) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); + /** Affiliate partner name. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; } - this.insurances.add(element); - return this; } + } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Guest { /** - * Add all elements to `insurances` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData#insurances} for the field - * documentation. + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. */ - public Builder addAllInsurance( - List elements) { - if (this.insurances == null) { - this.insurances = new ArrayList<>(); - } - this.insurances.addAll(elements); - return this; - } + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Whether the renter is a no-show. */ - public Builder setNoShowIndicator(Boolean noShowIndicator) { - this.noShowIndicator = noShowIndicator; - return this; - } + /** Required. Guest's full name. */ + @SerializedName("name") + Object name; - /** Renter ID number for the lodging. */ - public Builder setRenterIdNumber(String renterIdNumber) { - this.renterIdNumber = renterIdNumber; - return this; + private Guest(Map extraParams, Object name) { + this.extraParams = extraParams; + this.name = name; } - /** Renter ID number for the lodging. */ - public Builder setRenterIdNumber(EmptyParam renterIdNumber) { - this.renterIdNumber = renterIdNumber; - return this; + public static Builder builder() { + return new Builder(); } - /** Renter name for the lodging. */ - public Builder setRenterName(String renterName) { - this.renterName = renterName; - return this; - } + public static class Builder { + private Map extraParams; - /** Renter name for the lodging. */ - public Builder setRenterName(EmptyParam renterName) { - this.renterName = renterName; - return this; - } + private Object name; - /** Required. Total details for the lodging. */ - public Builder setTotal(PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total total) { - this.total = total; - return this; + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Guest build() { + return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Guest( + this.extraParams, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData.Guest#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData.Guest#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Required. Guest's full name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** Required. Guest's full name. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Accommodation { - /** Type of accommodation. */ - @SerializedName("accommodation_type") - AccommodationType accommodationType; - - /** Bed type. */ - @SerializedName("bed_type") - Object bedType; + public static class Host { + /** Address of the host. */ + @SerializedName("address") + Address address; - /** Daily accommodation rate in cents. */ - @SerializedName("daily_rate_amount") - Long dailyRateAmount; + /** Host's country of domicile. */ + @SerializedName("country_of_domicile") + Object countryOfDomicile; /** * Map of extra parameters for custom features not available in this client library. The @@ -12989,191 +14804,423 @@ public static class Accommodation { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Number of nights. */ - @SerializedName("nights") - Long nights; + /** Reference number for the host. */ + @SerializedName("host_reference") + Object hostReference; - /** Number of rooms, cabanas, apartments, and so on. */ - @SerializedName("number_of_rooms") - Long numberOfRooms; + /** Type of host. */ + @SerializedName("host_type") + HostType hostType; - /** Rate type. */ - @SerializedName("rate_type") - Object rateType; + /** Name of the lodging property or host. */ + @SerializedName("name") + Object name; - /** Whether smoking is allowed. */ - @SerializedName("smoking_indicator") - Boolean smokingIndicator; + /** Total number of reservations for the host. */ + @SerializedName("number_of_reservations") + Long numberOfReservations; - private Accommodation( - AccommodationType accommodationType, - Object bedType, - Long dailyRateAmount, + /** Property phone number. */ + @SerializedName("property_phone_number") + Object propertyPhoneNumber; + + /** Host's registration date. */ + @SerializedName("registered_at") + Long registeredAt; + + private Host( + Address address, + Object countryOfDomicile, Map extraParams, - Long nights, - Long numberOfRooms, - Object rateType, - Boolean smokingIndicator) { - this.accommodationType = accommodationType; - this.bedType = bedType; - this.dailyRateAmount = dailyRateAmount; + Object hostReference, + HostType hostType, + Object name, + Long numberOfReservations, + Object propertyPhoneNumber, + Long registeredAt) { + this.address = address; + this.countryOfDomicile = countryOfDomicile; this.extraParams = extraParams; - this.nights = nights; - this.numberOfRooms = numberOfRooms; - this.rateType = rateType; - this.smokingIndicator = smokingIndicator; + this.hostReference = hostReference; + this.hostType = hostType; + this.name = name; + this.numberOfReservations = numberOfReservations; + this.propertyPhoneNumber = propertyPhoneNumber; + this.registeredAt = registeredAt; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Address address; + + private Object countryOfDomicile; + + private Map extraParams; + + private Object hostReference; + + private HostType hostType; + + private Object name; + + private Long numberOfReservations; + + private Object propertyPhoneNumber; + + private Long registeredAt; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host build() { + return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host( + this.address, + this.countryOfDomicile, + this.extraParams, + this.hostReference, + this.hostType, + this.name, + this.numberOfReservations, + this.propertyPhoneNumber, + this.registeredAt); + } + + /** Address of the host. */ + public Builder setAddress( + PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host.Address address) { + this.address = address; + return this; + } + + /** Host's country of domicile. */ + public Builder setCountryOfDomicile(String countryOfDomicile) { + this.countryOfDomicile = countryOfDomicile; + return this; + } + + /** Host's country of domicile. */ + public Builder setCountryOfDomicile(EmptyParam countryOfDomicile) { + this.countryOfDomicile = countryOfDomicile; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Reference number for the host. */ + public Builder setHostReference(String hostReference) { + this.hostReference = hostReference; + return this; + } + + /** Reference number for the host. */ + public Builder setHostReference(EmptyParam hostReference) { + this.hostReference = hostReference; + return this; + } + + /** Type of host. */ + public Builder setHostType( + PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host.HostType hostType) { + this.hostType = hostType; + return this; + } + + /** Name of the lodging property or host. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** Name of the lodging property or host. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } + + /** Total number of reservations for the host. */ + public Builder setNumberOfReservations(Long numberOfReservations) { + this.numberOfReservations = numberOfReservations; + return this; + } + + /** Property phone number. */ + public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { + this.propertyPhoneNumber = propertyPhoneNumber; + return this; + } + + /** Property phone number. */ + public Builder setPropertyPhoneNumber(EmptyParam propertyPhoneNumber) { + this.propertyPhoneNumber = propertyPhoneNumber; + return this; + } + + /** Host's registration date. */ + public Builder setRegisteredAt(Long registeredAt) { + this.registeredAt = registeredAt; + return this; + } } - public static Builder builder() { - return new Builder(); - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Address { + /** Required. City, district, suburb, town, or village. */ + @SerializedName("city") + Object city; + + /** + * Required. Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + Object country; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** + * Required. Address line 1, such as the street, PO Box, or company name. + */ + @SerializedName("line1") + Object line1; + + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + Object line2; - public static class Builder { - private AccommodationType accommodationType; + /** Required. ZIP or postal code. */ + @SerializedName("postal_code") + Object postalCode; - private Object bedType; + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + Object state; - private Long dailyRateAmount; + private Address( + Object city, + Object country, + Map extraParams, + Object line1, + Object line2, + Object postalCode, + Object state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } - private Map extraParams; + public static Builder builder() { + return new Builder(); + } - private Long nights; + public static class Builder { + private Object city; - private Long numberOfRooms; + private Object country; - private Object rateType; + private Map extraParams; - private Boolean smokingIndicator; + private Object line1; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Accommodation build() { - return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Accommodation( - this.accommodationType, - this.bedType, - this.dailyRateAmount, - this.extraParams, - this.nights, - this.numberOfRooms, - this.rateType, - this.smokingIndicator); - } + private Object line2; - /** Type of accommodation. */ - public Builder setAccommodationType( - PaymentIntentUpdateParams.PaymentDetails.LodgingData.Accommodation.AccommodationType - accommodationType) { - this.accommodationType = accommodationType; - return this; - } + private Object postalCode; - /** Bed type. */ - public Builder setBedType(String bedType) { - this.bedType = bedType; - return this; - } + private Object state; - /** Bed type. */ - public Builder setBedType(EmptyParam bedType) { - this.bedType = bedType; - return this; - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host.Address build() { + return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } - /** Daily accommodation rate in cents. */ - public Builder setDailyRateAmount(Long dailyRateAmount) { - this.dailyRateAmount = dailyRateAmount; - return this; - } + /** Required. City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Accommodation#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** Required. City, district, suburb, town, or village. */ + public Builder setCity(EmptyParam city) { + this.city = city; + return this; } - this.extraParams.put(key, value); - return this; - } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Accommodation#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** + * Required. Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; } - this.extraParams.putAll(map); - return this; - } - /** Number of nights. */ - public Builder setNights(Long nights) { - this.nights = nights; - return this; - } + /** + * Required. Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(EmptyParam country) { + this.country = country; + return this; + } - /** Number of rooms, cabanas, apartments, and so on. */ - public Builder setNumberOfRooms(Long numberOfRooms) { - this.numberOfRooms = numberOfRooms; - return this; - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host.Address#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** Rate type. */ - public Builder setRateType(String rateType) { - this.rateType = rateType; - return this; - } + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host.Address#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** Rate type. */ - public Builder setRateType(EmptyParam rateType) { - this.rateType = rateType; - return this; - } + /** + * Required. Address line 1, such as the street, PO Box, or company + * name. + */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } - /** Whether smoking is allowed. */ - public Builder setSmokingIndicator(Boolean smokingIndicator) { - this.smokingIndicator = smokingIndicator; - return this; - } - } + /** + * Required. Address line 1, such as the street, PO Box, or company + * name. + */ + public Builder setLine1(EmptyParam line1) { + this.line1 = line1; + return this; + } - public enum AccommodationType implements ApiRequestParams.EnumParam { - @SerializedName("apartment") - APARTMENT("apartment"), + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } - @SerializedName("cabana") - CABANA("cabana"), + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(EmptyParam line2) { + this.line2 = line2; + return this; + } - @SerializedName("house") - HOUSE("house"), + /** Required. ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - @SerializedName("penthouse") - PENTHOUSE("penthouse"), + /** Required. ZIP or postal code. */ + public Builder setPostalCode(EmptyParam postalCode) { + this.postalCode = postalCode; + return this; + } + + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(EmptyParam state) { + this.state = state; + return this; + } + } + } - @SerializedName("room") - ROOM("room"), + public enum HostType implements ApiRequestParams.EnumParam { + @SerializedName("hostel") + HOSTEL("hostel"), - @SerializedName("standard") - STANDARD("standard"), + @SerializedName("hotel") + HOTEL("hotel"), - @SerializedName("suite") - SUITE("suite"), + @SerializedName("owner") + OWNER("owner"), - @SerializedName("villa") - VILLA("villa"); + @SerializedName("rental_agency") + RENTAL_AGENCY("rental_agency"); @Getter(onMethod_ = {@Override}) private final String value; - AccommodationType(String value) { + HostType(String value) { this.value = value; } } @@ -13181,10 +15228,14 @@ public enum AccommodationType implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) - public static class Affiliate { - /** Affiliate partner code. */ - @SerializedName("code") - Object code; + public static class Insurance { + /** Required. Price of the insurance coverage in cents. */ + @SerializedName("amount") + Long amount; + + /** Currency of the insurance amount. */ + @SerializedName("currency") + Object currency; /** * Map of extra parameters for custom features not available in this client library. The @@ -13196,14 +15247,25 @@ public static class Affiliate { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Affiliate partner name. */ - @SerializedName("name") - Object name; + /** Name of the insurance company. */ + @SerializedName("insurance_company_name") + Object insuranceCompanyName; - private Affiliate(Object code, Map extraParams, Object name) { - this.code = code; + /** Required. Type of insurance coverage. */ + @SerializedName("insurance_type") + InsuranceType insuranceType; + + private Insurance( + Long amount, + Object currency, + Map extraParams, + Object insuranceCompanyName, + InsuranceType insuranceType) { + this.amount = amount; + this.currency = currency; this.extraParams = extraParams; - this.name = name; + this.insuranceCompanyName = insuranceCompanyName; + this.insuranceType = insuranceType; } public static Builder builder() { @@ -13211,27 +15273,41 @@ public static Builder builder() { } public static class Builder { - private Object code; + private Long amount; + + private Object currency; private Map extraParams; - private Object name; + private Object insuranceCompanyName; + + private InsuranceType insuranceType; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Affiliate build() { - return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Affiliate( - this.code, this.extraParams, this.name); + public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Insurance build() { + return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Insurance( + this.amount, + this.currency, + this.extraParams, + this.insuranceCompanyName, + this.insuranceType); } - /** Affiliate partner code. */ - public Builder setCode(String code) { - this.code = code; + /** Required. Price of the insurance coverage in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; return this; } - /** Affiliate partner code. */ - public Builder setCode(EmptyParam code) { - this.code = code; + /** Currency of the insurance amount. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; + } + + /** Currency of the insurance amount. */ + public Builder setCurrency(EmptyParam currency) { + this.currency = currency; return this; } @@ -13239,7 +15315,7 @@ public Builder setCode(EmptyParam code) { * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original * map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Affiliate#extraParams} for the + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Insurance#extraParams} for the * field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -13254,7 +15330,7 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original * map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Affiliate#extraParams} for the + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Insurance#extraParams} for the * field documentation. */ public Builder putAllExtraParam(Map map) { @@ -13265,109 +15341,71 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Affiliate partner name. */ - public Builder setName(String name) { - this.name = name; + /** Name of the insurance company. */ + public Builder setInsuranceCompanyName(String insuranceCompanyName) { + this.insuranceCompanyName = insuranceCompanyName; return this; } - /** Affiliate partner name. */ - public Builder setName(EmptyParam name) { - this.name = name; + /** Name of the insurance company. */ + public Builder setInsuranceCompanyName(EmptyParam insuranceCompanyName) { + this.insuranceCompanyName = insuranceCompanyName; return this; } - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Guest { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; - - /** Required. Guest's full name. */ - @SerializedName("name") - Object name; - - private Guest(Map extraParams, Object name) { - this.extraParams = extraParams; - this.name = name; - } - public static Builder builder() { - return new Builder(); + /** Required. Type of insurance coverage. */ + public Builder setInsuranceType( + PaymentIntentUpdateParams.PaymentDetails.LodgingData.Insurance.InsuranceType + insuranceType) { + this.insuranceType = insuranceType; + return this; + } } - public static class Builder { - private Map extraParams; - - private Object name; + public enum InsuranceType implements ApiRequestParams.EnumParam { + @SerializedName("bankruptcy") + BANKRUPTCY("bankruptcy"), - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Guest build() { - return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Guest( - this.extraParams, this.name); - } + @SerializedName("cancelation") + CANCELATION("cancelation"), - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData.Guest#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + @SerializedName("emergency") + EMERGENCY("emergency"), - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData.Guest#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + @SerializedName("medical") + MEDICAL("medical"); - /** Required. Guest's full name. */ - public Builder setName(String name) { - this.name = name; - return this; - } + @Getter(onMethod_ = {@Override}) + private final String value; - /** Required. Guest's full name. */ - public Builder setName(EmptyParam name) { - this.name = name; - return this; + InsuranceType(String value) { + this.value = value; } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Host { - /** Address of the host. */ - @SerializedName("address") - Address address; + public static class Total { + /** Required. Total price of the lodging reservation in cents. */ + @SerializedName("amount") + Long amount; - /** Host's country of domicile. */ - @SerializedName("country_of_domicile") - Object countryOfDomicile; + /** Cash advances in cents. */ + @SerializedName("cash_advances") + Long cashAdvances; + + /** Currency of the total amount. */ + @SerializedName("currency") + Object currency; + + /** Discount details for the lodging. */ + @SerializedName("discounts") + Discounts discounts; + + /** Additional charges for the lodging. */ + @SerializedName("extra_charges") + List extraCharges; /** * Map of extra parameters for custom features not available in this client library. The @@ -13379,49 +15417,32 @@ public static class Host { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Reference number for the host. */ - @SerializedName("host_reference") - Object hostReference; - - /** Type of host. */ - @SerializedName("host_type") - HostType hostType; - - /** Name of the lodging property or host. */ - @SerializedName("name") - Object name; - - /** Total number of reservations for the host. */ - @SerializedName("number_of_reservations") - Long numberOfReservations; - - /** Property phone number. */ - @SerializedName("property_phone_number") - Object propertyPhoneNumber; - - /** Host's registration date. */ - @SerializedName("registered_at") - Long registeredAt; + /** Prepaid amount in cents. */ + @SerializedName("prepaid_amount") + Long prepaidAmount; - private Host( - Address address, - Object countryOfDomicile, + /** Tax breakdown for the lodging reservation. */ + @SerializedName("tax") + Tax tax; + + private Total( + Long amount, + Long cashAdvances, + Object currency, + Discounts discounts, + List + extraCharges, Map extraParams, - Object hostReference, - HostType hostType, - Object name, - Long numberOfReservations, - Object propertyPhoneNumber, - Long registeredAt) { - this.address = address; - this.countryOfDomicile = countryOfDomicile; + Long prepaidAmount, + Tax tax) { + this.amount = amount; + this.cashAdvances = cashAdvances; + this.currency = currency; + this.discounts = discounts; + this.extraCharges = extraCharges; this.extraParams = extraParams; - this.hostReference = hostReference; - this.hostType = hostType; - this.name = name; - this.numberOfReservations = numberOfReservations; - this.propertyPhoneNumber = propertyPhoneNumber; - this.registeredAt = registeredAt; + this.prepaidAmount = prepaidAmount; + this.tax = tax; } public static Builder builder() { @@ -13429,61 +15450,102 @@ public static Builder builder() { } public static class Builder { - private Address address; - - private Object countryOfDomicile; + private Long amount; - private Map extraParams; + private Long cashAdvances; - private Object hostReference; + private Object currency; - private HostType hostType; + private Discounts discounts; - private Object name; + private List + extraCharges; - private Long numberOfReservations; + private Map extraParams; - private Object propertyPhoneNumber; + private Long prepaidAmount; - private Long registeredAt; + private Tax tax; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host build() { - return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host( - this.address, - this.countryOfDomicile, + public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total build() { + return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total( + this.amount, + this.cashAdvances, + this.currency, + this.discounts, + this.extraCharges, this.extraParams, - this.hostReference, - this.hostType, - this.name, - this.numberOfReservations, - this.propertyPhoneNumber, - this.registeredAt); + this.prepaidAmount, + this.tax); } - /** Address of the host. */ - public Builder setAddress( - PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host.Address address) { - this.address = address; + /** Required. Total price of the lodging reservation in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; return this; } - /** Host's country of domicile. */ - public Builder setCountryOfDomicile(String countryOfDomicile) { - this.countryOfDomicile = countryOfDomicile; + /** Cash advances in cents. */ + public Builder setCashAdvances(Long cashAdvances) { + this.cashAdvances = cashAdvances; return this; } - /** Host's country of domicile. */ - public Builder setCountryOfDomicile(EmptyParam countryOfDomicile) { - this.countryOfDomicile = countryOfDomicile; + /** Currency of the total amount. */ + public Builder setCurrency(String currency) { + this.currency = currency; + return this; + } + + /** Currency of the total amount. */ + public Builder setCurrency(EmptyParam currency) { + this.currency = currency; + return this; + } + + /** Discount details for the lodging. */ + public Builder setDiscounts( + PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Discounts discounts) { + this.discounts = discounts; + return this; + } + + /** + * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total#extraCharges} for the field + * documentation. + */ + public Builder addExtraCharge( + PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge element) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.add(element); + return this; + } + + /** + * Add all elements to `extraCharges` list. A list is initialized for the first + * `add/addAll` call, and subsequent calls adds additional elements to the original list. + * See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total#extraCharges} for + * the field documentation. + */ + public Builder addAllExtraCharge( + List + elements) { + if (this.extraCharges == null) { + this.extraCharges = new ArrayList<>(); + } + this.extraCharges.addAll(elements); return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host#extraParams} + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total#extraParams} * for the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -13497,7 +15559,7 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host#extraParams} + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total#extraParams} * for the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -13508,75 +15570,127 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Reference number for the host. */ - public Builder setHostReference(String hostReference) { - this.hostReference = hostReference; + /** Prepaid amount in cents. */ + public Builder setPrepaidAmount(Long prepaidAmount) { + this.prepaidAmount = prepaidAmount; return this; } - /** Reference number for the host. */ - public Builder setHostReference(EmptyParam hostReference) { - this.hostReference = hostReference; + /** Tax breakdown for the lodging reservation. */ + public Builder setTax( + PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax tax) { + this.tax = tax; return this; } + } - /** Type of host. */ - public Builder setHostType( - PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host.HostType hostType) { - this.hostType = hostType; - return this; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Discounts { + /** Corporate client discount code. */ + @SerializedName("corporate_client_code") + Object corporateClientCode; - /** Name of the lodging property or host. */ - public Builder setName(String name) { - this.name = name; - return this; - } + /** Coupon code. */ + @SerializedName("coupon") + Object coupon; - /** Name of the lodging property or host. */ - public Builder setName(EmptyParam name) { - this.name = name; - return this; - } + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Total number of reservations for the host. */ - public Builder setNumberOfReservations(Long numberOfReservations) { - this.numberOfReservations = numberOfReservations; - return this; + private Discounts( + Object corporateClientCode, Object coupon, Map extraParams) { + this.corporateClientCode = corporateClientCode; + this.coupon = coupon; + this.extraParams = extraParams; } - /** Property phone number. */ - public Builder setPropertyPhoneNumber(String propertyPhoneNumber) { - this.propertyPhoneNumber = propertyPhoneNumber; - return this; + public static Builder builder() { + return new Builder(); } - /** Property phone number. */ - public Builder setPropertyPhoneNumber(EmptyParam propertyPhoneNumber) { - this.propertyPhoneNumber = propertyPhoneNumber; - return this; - } + public static class Builder { + private Object corporateClientCode; + + private Object coupon; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Discounts build() { + return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Discounts( + this.corporateClientCode, this.coupon, this.extraParams); + } + + /** Corporate client discount code. */ + public Builder setCorporateClientCode(String corporateClientCode) { + this.corporateClientCode = corporateClientCode; + return this; + } + + /** Corporate client discount code. */ + public Builder setCorporateClientCode(EmptyParam corporateClientCode) { + this.corporateClientCode = corporateClientCode; + return this; + } + + /** Coupon code. */ + public Builder setCoupon(String coupon) { + this.coupon = coupon; + return this; + } + + /** Coupon code. */ + public Builder setCoupon(EmptyParam coupon) { + this.coupon = coupon; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** Host's registration date. */ - public Builder setRegisteredAt(Long registeredAt) { - this.registeredAt = registeredAt; - return this; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Address { - /** Required. City, district, suburb, town, or village. */ - @SerializedName("city") - Object city; - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - @SerializedName("country") - Object country; + public static class ExtraCharge { + /** Amount of the extra charge in cents. */ + @SerializedName("amount") + Long amount; /** * Map of extra parameters for custom features not available in this client library. The @@ -13588,42 +15702,14 @@ public static class Address { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** - * Required. Address line 1, such as the street, PO Box, or company name. - */ - @SerializedName("line1") - Object line1; - - /** Address line 2, such as the apartment, suite, unit, or building. */ - @SerializedName("line2") - Object line2; - - /** Required. ZIP or postal code. */ - @SerializedName("postal_code") - Object postalCode; - - /** - * State, county, province, or region (ISO 3166-2). - */ - @SerializedName("state") - Object state; + /** Type of extra charge. */ + @SerializedName("type") + Type type; - private Address( - Object city, - Object country, - Map extraParams, - Object line1, - Object line2, - Object postalCode, - Object state) { - this.city = city; - this.country = country; + private ExtraCharge(Long amount, Map extraParams, Type type) { + this.amount = amount; this.extraParams = extraParams; - this.line1 = line1; - this.line2 = line2; - this.postalCode = postalCode; - this.state = state; + this.type = type; } public static Builder builder() { @@ -13631,59 +15717,21 @@ public static Builder builder() { } public static class Builder { - private Object city; - - private Object country; + private Long amount; private Map extraParams; - private Object line1; - - private Object line2; - - private Object postalCode; - - private Object state; + private Type type; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host.Address build() { - return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host.Address( - this.city, - this.country, - this.extraParams, - this.line1, - this.line2, - this.postalCode, - this.state); - } - - /** Required. City, district, suburb, town, or village. */ - public Builder setCity(String city) { - this.city = city; - return this; - } - - /** Required. City, district, suburb, town, or village. */ - public Builder setCity(EmptyParam city) { - this.city = city; - return this; - } - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - public Builder setCountry(String country) { - this.country = country; - return this; + public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge build() { + return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge( + this.amount, this.extraParams, this.type); } - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - public Builder setCountry(EmptyParam country) { - this.country = country; + /** Amount of the extra charge in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; return this; } @@ -13691,8 +15739,8 @@ public Builder setCountry(EmptyParam country) { * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host.Address#extraParams} for - * the field documentation. + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -13706,8 +15754,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Host.Address#extraParams} for - * the field documentation. + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -13717,270 +15765,381 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Required. Address line 1, such as the street, PO Box, or company - * name. - */ - public Builder setLine1(String line1) { - this.line1 = line1; + /** Type of extra charge. */ + public Builder setType( + PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge.Type type) { + this.type = type; return this; } + } - /** - * Required. Address line 1, such as the street, PO Box, or company - * name. - */ - public Builder setLine1(EmptyParam line1) { - this.line1 = line1; - return this; + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("gift_shop") + GIFT_SHOP("gift_shop"), + + @SerializedName("laundry") + LAUNDRY("laundry"), + + @SerializedName("mini_bar") + MINI_BAR("mini_bar"), + + @SerializedName("other") + OTHER("other"), + + @SerializedName("phone") + PHONE("phone"), + + @SerializedName("restaurant") + RESTAURANT("restaurant"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Type(String value) { + this.value = value; } + } + } - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(String line2) { - this.line2 = line2; - return this; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Tax { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Indicates whether the transaction is tax exempt. */ + @SerializedName("tax_exempt_indicator") + Boolean taxExemptIndicator; + + /** Tax details. */ + @SerializedName("taxes") + List taxes; + + private Tax( + Map extraParams, + Boolean taxExemptIndicator, + List taxes) { + this.extraParams = extraParams; + this.taxExemptIndicator = taxExemptIndicator; + this.taxes = taxes; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Boolean taxExemptIndicator; + + private List + taxes; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax build() { + return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax( + this.extraParams, this.taxExemptIndicator, this.taxes); } - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(EmptyParam line2) { - this.line2 = line2; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the + * field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); return this; } - /** Required. ZIP or postal code. */ - public Builder setPostalCode(String postalCode) { - this.postalCode = postalCode; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); return this; } - /** Required. ZIP or postal code. */ - public Builder setPostalCode(EmptyParam postalCode) { - this.postalCode = postalCode; + /** Indicates whether the transaction is tax exempt. */ + public Builder setTaxExemptIndicator(Boolean taxExemptIndicator) { + this.taxExemptIndicator = taxExemptIndicator; return this; } /** - * State, county, province, or region (ISO 3166-2). + * Add an element to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field + * documentation. */ - public Builder setState(String state) { - this.state = state; + public Builder addTax( + PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax element) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.add(element); return this; } /** - * State, county, province, or region (ISO 3166-2). + * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field + * documentation. */ - public Builder setState(EmptyParam state) { - this.state = state; + public Builder addAllTax( + List + elements) { + if (this.taxes == null) { + this.taxes = new ArrayList<>(); + } + this.taxes.addAll(elements); return this; } } - } - - public enum HostType implements ApiRequestParams.EnumParam { - @SerializedName("hostel") - HOSTEL("hostel"), - - @SerializedName("hotel") - HOTEL("hotel"), - @SerializedName("owner") - OWNER("owner"), + @Getter + @EqualsAndHashCode(callSuper = false) + public static class InnerTax { + /** Tax amount in cents. */ + @SerializedName("amount") + Long amount; - @SerializedName("rental_agency") - RENTAL_AGENCY("rental_agency"); + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - @Getter(onMethod_ = {@Override}) - private final String value; + /** Tax rate. */ + @SerializedName("rate") + Long rate; - HostType(String value) { - this.value = value; - } - } - } + /** Type of tax applied. */ + @SerializedName("type") + Object type; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Insurance { - /** Required. Price of the insurance coverage in cents. */ - @SerializedName("amount") - Long amount; + private InnerTax(Long amount, Map extraParams, Long rate, Object type) { + this.amount = amount; + this.extraParams = extraParams; + this.rate = rate; + this.type = type; + } - /** Currency of the insurance amount. */ - @SerializedName("currency") - Object currency; + public static Builder builder() { + return new Builder(); + } - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + public static class Builder { + private Long amount; - /** Name of the insurance company. */ - @SerializedName("insurance_company_name") - Object insuranceCompanyName; + private Map extraParams; - /** Required. Type of insurance coverage. */ - @SerializedName("insurance_type") - InsuranceType insuranceType; + private Long rate; - private Insurance( - Long amount, - Object currency, - Map extraParams, - Object insuranceCompanyName, - InsuranceType insuranceType) { - this.amount = amount; - this.currency = currency; - this.extraParams = extraParams; - this.insuranceCompanyName = insuranceCompanyName; - this.insuranceType = insuranceType; - } + private Object type; - public static Builder builder() { - return new Builder(); - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax + build() { + return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax( + this.amount, this.extraParams, this.rate, this.type); + } - public static class Builder { - private Long amount; + /** Tax amount in cents. */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } - private Object currency; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - private Map extraParams; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - private Object insuranceCompanyName; + /** Tax rate. */ + public Builder setRate(Long rate) { + this.rate = rate; + return this; + } - private InsuranceType insuranceType; + /** Type of tax applied. */ + public Builder setType(String type) { + this.type = type; + return this; + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Insurance build() { - return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Insurance( - this.amount, - this.currency, - this.extraParams, - this.insuranceCompanyName, - this.insuranceType); + /** Type of tax applied. */ + public Builder setType(EmptyParam type) { + this.type = type; + return this; + } + } } + } + } + } - /** Required. Price of the insurance coverage in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Account funding transaction details including sender and beneficiary information. */ + @SerializedName("account_funding") + Object accountFunding; - /** Currency of the insurance amount. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; - } + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Currency of the insurance amount. */ - public Builder setCurrency(EmptyParam currency) { - this.currency = currency; - return this; - } + /** The type of money services transaction. */ + @SerializedName("transaction_type") + ApiRequestParams.EnumParam transactionType; - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Insurance#extraParams} for the - * field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + private MoneyServices( + Object accountFunding, + Map extraParams, + ApiRequestParams.EnumParam transactionType) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + this.transactionType = transactionType; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Insurance#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + public static Builder builder() { + return new Builder(); + } - /** Name of the insurance company. */ - public Builder setInsuranceCompanyName(String insuranceCompanyName) { - this.insuranceCompanyName = insuranceCompanyName; - return this; - } + public static class Builder { + private Object accountFunding; - /** Name of the insurance company. */ - public Builder setInsuranceCompanyName(EmptyParam insuranceCompanyName) { - this.insuranceCompanyName = insuranceCompanyName; - return this; - } + private Map extraParams; - /** Required. Type of insurance coverage. */ - public Builder setInsuranceType( - PaymentIntentUpdateParams.PaymentDetails.LodgingData.Insurance.InsuranceType - insuranceType) { - this.insuranceType = insuranceType; - return this; - } + private ApiRequestParams.EnumParam transactionType; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.MoneyServices build() { + return new PaymentIntentUpdateParams.PaymentDetails.MoneyServices( + this.accountFunding, this.extraParams, this.transactionType); } - public enum InsuranceType implements ApiRequestParams.EnumParam { - @SerializedName("bankruptcy") - BANKRUPTCY("bankruptcy"), + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding( + PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { + this.accountFunding = accountFunding; + return this; + } - @SerializedName("cancelation") - CANCELATION("cancelation"), + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding(EmptyParam accountFunding) { + this.accountFunding = accountFunding; + return this; + } - @SerializedName("emergency") - EMERGENCY("emergency"), + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.MoneyServices#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - @SerializedName("medical") - MEDICAL("medical"); + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link PaymentIntentUpdateParams.PaymentDetails.MoneyServices#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** The type of money services transaction. */ + public Builder setTransactionType( + PaymentIntentUpdateParams.PaymentDetails.MoneyServices.TransactionType + transactionType) { + this.transactionType = transactionType; + return this; + } - InsuranceType(String value) { - this.value = value; - } + /** The type of money services transaction. */ + public Builder setTransactionType(EmptyParam transactionType) { + this.transactionType = transactionType; + return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Total { - /** Required. Total price of the lodging reservation in cents. */ - @SerializedName("amount") - Long amount; - - /** Cash advances in cents. */ - @SerializedName("cash_advances") - Long cashAdvances; - - /** Currency of the total amount. */ - @SerializedName("currency") - Object currency; - - /** Discount details for the lodging. */ - @SerializedName("discounts") - Discounts discounts; + public static class AccountFunding { + /** ID of the Account representing the beneficiary in this account funding transaction. */ + @SerializedName("beneficiary_account") + Object beneficiaryAccount; - /** Additional charges for the lodging. */ - @SerializedName("extra_charges") - List extraCharges; + /** Inline identity details for the beneficiary of this account funding transaction. */ + @SerializedName("beneficiary_details") + Object beneficiaryDetails; /** * Map of extra parameters for custom features not available in this client library. The @@ -13992,32 +16151,25 @@ public static class Total { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Prepaid amount in cents. */ - @SerializedName("prepaid_amount") - Long prepaidAmount; + /** ID of the Account representing the sender in this account funding transaction. */ + @SerializedName("sender_account") + Object senderAccount; - /** Tax breakdown for the lodging reservation. */ - @SerializedName("tax") - Tax tax; + /** Inline identity details for the sender of this account funding transaction. */ + @SerializedName("sender_details") + Object senderDetails; - private Total( - Long amount, - Long cashAdvances, - Object currency, - Discounts discounts, - List - extraCharges, + private AccountFunding( + Object beneficiaryAccount, + Object beneficiaryDetails, Map extraParams, - Long prepaidAmount, - Tax tax) { - this.amount = amount; - this.cashAdvances = cashAdvances; - this.currency = currency; - this.discounts = discounts; - this.extraCharges = extraCharges; + Object senderAccount, + Object senderDetails) { + this.beneficiaryAccount = beneficiaryAccount; + this.beneficiaryDetails = beneficiaryDetails; this.extraParams = extraParams; - this.prepaidAmount = prepaidAmount; - this.tax = tax; + this.senderAccount = senderAccount; + this.senderDetails = senderDetails; } public static Builder builder() { @@ -14025,103 +16177,59 @@ public static Builder builder() { } public static class Builder { - private Long amount; - - private Long cashAdvances; + private Object beneficiaryAccount; - private Object currency; - - private Discounts discounts; - - private List - extraCharges; + private Object beneficiaryDetails; private Map extraParams; - private Long prepaidAmount; + private Object senderAccount; - private Tax tax; + private Object senderDetails; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total build() { - return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total( - this.amount, - this.cashAdvances, - this.currency, - this.discounts, - this.extraCharges, + public PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding build() { + return new PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding( + this.beneficiaryAccount, + this.beneficiaryDetails, this.extraParams, - this.prepaidAmount, - this.tax); - } - - /** Required. Total price of the lodging reservation in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; - } - - /** Cash advances in cents. */ - public Builder setCashAdvances(Long cashAdvances) { - this.cashAdvances = cashAdvances; - return this; - } - - /** Currency of the total amount. */ - public Builder setCurrency(String currency) { - this.currency = currency; - return this; + this.senderAccount, + this.senderDetails); } - /** Currency of the total amount. */ - public Builder setCurrency(EmptyParam currency) { - this.currency = currency; + /** ID of the Account representing the beneficiary in this account funding transaction. */ + public Builder setBeneficiaryAccount(String beneficiaryAccount) { + this.beneficiaryAccount = beneficiaryAccount; return this; } - /** Discount details for the lodging. */ - public Builder setDiscounts( - PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Discounts discounts) { - this.discounts = discounts; + /** ID of the Account representing the beneficiary in this account funding transaction. */ + public Builder setBeneficiaryAccount(EmptyParam beneficiaryAccount) { + this.beneficiaryAccount = beneficiaryAccount; return this; } - /** - * Add an element to `extraCharges` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total#extraCharges} for the field - * documentation. - */ - public Builder addExtraCharge( - PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge element) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.add(element); + /** Inline identity details for the beneficiary of this account funding transaction. */ + public Builder setBeneficiaryDetails( + PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails + beneficiaryDetails) { + this.beneficiaryDetails = beneficiaryDetails; return this; } - /** - * Add all elements to `extraCharges` list. A list is initialized for the first - * `add/addAll` call, and subsequent calls adds additional elements to the original list. - * See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total#extraCharges} for - * the field documentation. - */ - public Builder addAllExtraCharge( - List - elements) { - if (this.extraCharges == null) { - this.extraCharges = new ArrayList<>(); - } - this.extraCharges.addAll(elements); + /** Inline identity details for the beneficiary of this account funding transaction. */ + public Builder setBeneficiaryDetails(EmptyParam beneficiaryDetails) { + this.beneficiaryDetails = beneficiaryDetails; return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for + * the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -14134,8 +16242,9 @@ public Builder putExtraParam(String key, Object value) { /** * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total#extraParams} - * for the field documentation. + * map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for + * the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -14145,30 +16254,47 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Prepaid amount in cents. */ - public Builder setPrepaidAmount(Long prepaidAmount) { - this.prepaidAmount = prepaidAmount; + /** ID of the Account representing the sender in this account funding transaction. */ + public Builder setSenderAccount(String senderAccount) { + this.senderAccount = senderAccount; return this; } - /** Tax breakdown for the lodging reservation. */ - public Builder setTax( - PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax tax) { - this.tax = tax; + /** ID of the Account representing the sender in this account funding transaction. */ + public Builder setSenderAccount(EmptyParam senderAccount) { + this.senderAccount = senderAccount; + return this; + } + + /** Inline identity details for the sender of this account funding transaction. */ + public Builder setSenderDetails( + PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + senderDetails) { + this.senderDetails = senderDetails; + return this; + } + + /** Inline identity details for the sender of this account funding transaction. */ + public Builder setSenderDetails(EmptyParam senderDetails) { + this.senderDetails = senderDetails; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Discounts { - /** Corporate client discount code. */ - @SerializedName("corporate_client_code") - Object corporateClientCode; + public static class BeneficiaryDetails { + /** Address. */ + @SerializedName("address") + Address address; - /** Coupon code. */ - @SerializedName("coupon") - Object coupon; + /** Date of birth. */ + @SerializedName("date_of_birth") + DateOfBirth dateOfBirth; + + /** Email address. */ + @SerializedName("email") + Object email; /** * Map of extra parameters for custom features not available in this client library. The @@ -14180,11 +16306,27 @@ public static class Discounts { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private Discounts( - Object corporateClientCode, Object coupon, Map extraParams) { - this.corporateClientCode = corporateClientCode; - this.coupon = coupon; + /** Full name. */ + @SerializedName("name") + Object name; + + /** Phone number. */ + @SerializedName("phone") + Object phone; + + private BeneficiaryDetails( + Address address, + DateOfBirth dateOfBirth, + Object email, + Map extraParams, + Object name, + Object phone) { + this.address = address; + this.dateOfBirth = dateOfBirth; + this.email = email; this.extraParams = extraParams; + this.name = name; + this.phone = phone; } public static Builder builder() { @@ -14192,39 +16334,59 @@ public static Builder builder() { } public static class Builder { - private Object corporateClientCode; + private Address address; - private Object coupon; + private DateOfBirth dateOfBirth; + + private Object email; private Map extraParams; + private Object name; + + private Object phone; + /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Discounts build() { - return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Discounts( - this.corporateClientCode, this.coupon, this.extraParams); + public PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails + build() { + return new PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails( + this.address, + this.dateOfBirth, + this.email, + this.extraParams, + this.name, + this.phone); } - /** Corporate client discount code. */ - public Builder setCorporateClientCode(String corporateClientCode) { - this.corporateClientCode = corporateClientCode; + /** Address. */ + public Builder setAddress( + PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.Address + address) { + this.address = address; return this; } - /** Corporate client discount code. */ - public Builder setCorporateClientCode(EmptyParam corporateClientCode) { - this.corporateClientCode = corporateClientCode; + /** Date of birth. */ + public Builder setDateOfBirth( + PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.DateOfBirth + dateOfBirth) { + this.dateOfBirth = dateOfBirth; return this; } - /** Coupon code. */ - public Builder setCoupon(String coupon) { - this.coupon = coupon; + /** Email address. */ + public Builder setEmail(String email) { + this.email = email; return this; } - /** Coupon code. */ - public Builder setCoupon(EmptyParam coupon) { - this.coupon = coupon; + /** Email address. */ + public Builder setEmail(EmptyParam email) { + this.email = email; return this; } @@ -14232,8 +16394,8 @@ public Builder setCoupon(EmptyParam coupon) { * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} for - * the field documentation. + * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -14247,8 +16409,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Discounts#extraParams} for - * the field documentation. + * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -14257,128 +16419,362 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } - } - } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class ExtraCharge { - /** Amount of the extra charge in cents. */ - @SerializedName("amount") - Long amount; + /** Full name. */ + public Builder setName(String name) { + this.name = name; + return this; + } - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its - * parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** Full name. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } - /** Type of extra charge. */ - @SerializedName("type") - Type type; + /** Phone number. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } - private ExtraCharge(Long amount, Map extraParams, Type type) { - this.amount = amount; - this.extraParams = extraParams; - this.type = type; + /** Phone number. */ + public Builder setPhone(EmptyParam phone) { + this.phone = phone; + return this; + } } - public static Builder builder() { - return new Builder(); - } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Address { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + Object city; - public static class Builder { - private Long amount; + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + Object country; - private Map extraParams; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - private Type type; + /** Address line 1, such as the street, PO Box, or company name. */ + @SerializedName("line1") + Object line1; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge build() { - return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge( - this.amount, this.extraParams, this.type); + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + Object line2; + + /** ZIP or postal code. */ + @SerializedName("postal_code") + Object postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + Object state; + + private Address( + Object city, + Object country, + Map extraParams, + Object line1, + Object line2, + Object postalCode, + Object state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; } - /** Amount of the extra charge in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; - return this; + public static Builder builder() { + return new Builder(); } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + public static class Builder { + private Object city; + + private Object country; + + private Map extraParams; + + private Object line1; + + private Object line2; + + private Object postalCode; + + private Object state; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.Address + build() { + return new PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } + + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** City, district, suburb, town, or village. */ + public Builder setCity(EmptyParam city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(EmptyParam country) { + this.country = country; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.Address#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.Address#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } + + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(EmptyParam line1) { + this.line1 = line1; + return this; + } + + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } + + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(EmptyParam line2) { + this.line2 = line2; + return this; + } + + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } + + /** ZIP or postal code. */ + public Builder setPostalCode(EmptyParam postalCode) { + this.postalCode = postalCode; + return this; + } + + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } + + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(EmptyParam state) { + this.state = state; + return this; } - this.extraParams.put(key, value); - return this; } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class DateOfBirth { + /** Required. Day of birth, between 1 and 31. */ + @SerializedName("day") + Long day; /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge#extraParams} - * for the field documentation. + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Required. Month of birth, between 1 and 12. */ + @SerializedName("month") + Long month; + + /** Required. Four-digit year of birth. */ + @SerializedName("year") + Long year; + + private DateOfBirth(Long day, Map extraParams, Long month, Long year) { + this.day = day; + this.extraParams = extraParams; + this.month = month; + this.year = year; } - /** Type of extra charge. */ - public Builder setType( - PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.ExtraCharge.Type type) { - this.type = type; - return this; + public static Builder builder() { + return new Builder(); } - } - public enum Type implements ApiRequestParams.EnumParam { - @SerializedName("gift_shop") - GIFT_SHOP("gift_shop"), + public static class Builder { + private Long day; - @SerializedName("laundry") - LAUNDRY("laundry"), + private Map extraParams; - @SerializedName("mini_bar") - MINI_BAR("mini_bar"), + private Long month; - @SerializedName("other") - OTHER("other"), + private Long year; - @SerializedName("phone") - PHONE("phone"), + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.DateOfBirth + build() { + return new PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .BeneficiaryDetails.DateOfBirth( + this.day, this.extraParams, this.month, this.year); + } - @SerializedName("restaurant") - RESTAURANT("restaurant"); + /** Required. Day of birth, between 1 and 31. */ + public Builder setDay(Long day) { + this.day = day; + return this; + } - @Getter(onMethod_ = {@Override}) - private final String value; + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - Type(String value) { - this.value = value; + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding.BeneficiaryDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Required. Month of birth, between 1 and 12. */ + public Builder setMonth(Long month) { + this.month = month; + return this; + } + + /** Required. Four-digit year of birth. */ + public Builder setYear(Long year) { + this.year = year; + return this; + } } } } @Getter @EqualsAndHashCode(callSuper = false) - public static class Tax { + public static class SenderDetails { + /** Address. */ + @SerializedName("address") + Address address; + + /** Date of birth. */ + @SerializedName("date_of_birth") + DateOfBirth dateOfBirth; + + /** Email address. */ + @SerializedName("email") + Object email; + /** * Map of extra parameters for custom features not available in this client library. The * content in this map is not serialized under this field's {@code @SerializedName} value. @@ -14389,21 +16785,27 @@ public static class Tax { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Indicates whether the transaction is tax exempt. */ - @SerializedName("tax_exempt_indicator") - Boolean taxExemptIndicator; + /** Full name. */ + @SerializedName("name") + Object name; - /** Tax details. */ - @SerializedName("taxes") - List taxes; + /** Phone number. */ + @SerializedName("phone") + Object phone; - private Tax( + private SenderDetails( + Address address, + DateOfBirth dateOfBirth, + Object email, Map extraParams, - Boolean taxExemptIndicator, - List taxes) { + Object name, + Object phone) { + this.address = address; + this.dateOfBirth = dateOfBirth; + this.email = email; this.extraParams = extraParams; - this.taxExemptIndicator = taxExemptIndicator; - this.taxes = taxes; + this.name = name; + this.phone = phone; } public static Builder builder() { @@ -14411,25 +16813,68 @@ public static Builder builder() { } public static class Builder { + private Address address; + + private DateOfBirth dateOfBirth; + + private Object email; + private Map extraParams; - private Boolean taxExemptIndicator; + private Object name; - private List - taxes; + private Object phone; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax build() { - return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax( - this.extraParams, this.taxExemptIndicator, this.taxes); + public PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails + build() { + return new PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails( + this.address, + this.dateOfBirth, + this.email, + this.extraParams, + this.name, + this.phone); + } + + /** Address. */ + public Builder setAddress( + PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + .Address + address) { + this.address = address; + return this; + } + + /** Date of birth. */ + public Builder setDateOfBirth( + PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails + .DateOfBirth + dateOfBirth) { + this.dateOfBirth = dateOfBirth; + return this; + } + + /** Email address. */ + public Builder setEmail(String email) { + this.email = email; + return this; + } + + /** Email address. */ + public Builder setEmail(EmptyParam email) { + this.email = email; + return this; } /** * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the - * field documentation. + * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails#extraParams} + * for the field documentation. */ public Builder putExtraParam(String key, Object value) { if (this.extraParams == null) { @@ -14443,8 +16888,8 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax#extraParams} for the - * field documentation. + * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails#extraParams} + * for the field documentation. */ public Builder putAllExtraParam(Map map) { if (this.extraParams == null) { @@ -14454,50 +16899,44 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Indicates whether the transaction is tax exempt. */ - public Builder setTaxExemptIndicator(Boolean taxExemptIndicator) { - this.taxExemptIndicator = taxExemptIndicator; + /** Full name. */ + public Builder setName(String name) { + this.name = name; return this; } - /** - * Add an element to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addTax( - PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax element) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.add(element); + /** Full name. */ + public Builder setName(EmptyParam name) { + this.name = name; return this; } - /** - * Add all elements to `taxes` list. A list is initialized for the first `add/addAll` - * call, and subsequent calls adds additional elements to the original list. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax#taxes} for the field - * documentation. - */ - public Builder addAllTax( - List - elements) { - if (this.taxes == null) { - this.taxes = new ArrayList<>(); - } - this.taxes.addAll(elements); + /** Phone number. */ + public Builder setPhone(String phone) { + this.phone = phone; + return this; + } + + /** Phone number. */ + public Builder setPhone(EmptyParam phone) { + this.phone = phone; return this; } } @Getter @EqualsAndHashCode(callSuper = false) - public static class InnerTax { - /** Tax amount in cents. */ - @SerializedName("amount") - Long amount; + public static class Address { + /** City, district, suburb, town, or village. */ + @SerializedName("city") + Object city; + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + @SerializedName("country") + Object country; /** * Map of extra parameters for custom features not available in this client library. The @@ -14509,19 +16948,40 @@ public static class InnerTax { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - /** Tax rate. */ - @SerializedName("rate") - Long rate; + /** Address line 1, such as the street, PO Box, or company name. */ + @SerializedName("line1") + Object line1; - /** Type of tax applied. */ - @SerializedName("type") - Object type; + /** Address line 2, such as the apartment, suite, unit, or building. */ + @SerializedName("line2") + Object line2; - private InnerTax(Long amount, Map extraParams, Long rate, Object type) { - this.amount = amount; + /** ZIP or postal code. */ + @SerializedName("postal_code") + Object postalCode; + + /** + * State, county, province, or region (ISO 3166-2). + */ + @SerializedName("state") + Object state; + + private Address( + Object city, + Object country, + Map extraParams, + Object line1, + Object line2, + Object postalCode, + Object state) { + this.city = city; + this.country = country; this.extraParams = extraParams; - this.rate = rate; - this.type = type; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; } public static Builder builder() { @@ -14529,24 +16989,62 @@ public static Builder builder() { } public static class Builder { - private Long amount; + private Object city; + + private Object country; private Map extraParams; - private Long rate; + private Object line1; - private Object type; + private Object line2; + + private Object postalCode; + + private Object state; /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax + public PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.Address build() { - return new PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax( - this.amount, this.extraParams, this.rate, this.type); + return new PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.Address( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); } - /** Tax amount in cents. */ - public Builder setAmount(Long amount) { - this.amount = amount; + /** City, district, suburb, town, or village. */ + public Builder setCity(String city) { + this.city = city; + return this; + } + + /** City, district, suburb, town, or village. */ + public Builder setCity(EmptyParam city) { + this.city = city; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(String country) { + this.country = country; + return this; + } + + /** + * Two-letter country code (ISO 3166-1 alpha-2). + */ + public Builder setCountry(EmptyParam country) { + this.country = country; return this; } @@ -14554,7 +17052,7 @@ public Builder setAmount(Long amount) { * Add a key/value pair to `extraParams` map. A map is initialized for the first * `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} + * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.Address#extraParams} * for the field documentation. */ public Builder putExtraParam(String key, Object value) { @@ -14569,7 +17067,7 @@ public Builder putExtraParam(String key, Object value) { * Add all map key/value pairs to `extraParams` map. A map is initialized for the * first `put/putAll` call, and subsequent calls add additional key/value pairs to the * original map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.LodgingData.Total.Tax.InnerTax#extraParams} + * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.Address#extraParams} * for the field documentation. */ public Builder putAllExtraParam(Map map) { @@ -14580,181 +17078,163 @@ public Builder putAllExtraParam(Map map) { return this; } - /** Tax rate. */ - public Builder setRate(Long rate) { - this.rate = rate; + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(String line1) { + this.line1 = line1; return this; } - /** Type of tax applied. */ - public Builder setType(String type) { - this.type = type; + /** Address line 1, such as the street, PO Box, or company name. */ + public Builder setLine1(EmptyParam line1) { + this.line1 = line1; return this; } - /** Type of tax applied. */ - public Builder setType(EmptyParam type) { - this.type = type; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(String line2) { + this.line2 = line2; return this; } - } - } - } - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class MoneyServices { - /** Account funding transaction details including sender and beneficiary information. */ - @SerializedName("account_funding") - Object accountFunding; - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) - * name in this param object. Effectively, this map is flattened to its parent instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + /** Address line 2, such as the apartment, suite, unit, or building. */ + public Builder setLine2(EmptyParam line2) { + this.line2 = line2; + return this; + } - /** The type of money services transaction. */ - @SerializedName("transaction_type") - TransactionType transactionType; + /** ZIP or postal code. */ + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } - private MoneyServices( - Object accountFunding, Map extraParams, TransactionType transactionType) { - this.accountFunding = accountFunding; - this.extraParams = extraParams; - this.transactionType = transactionType; - } + /** ZIP or postal code. */ + public Builder setPostalCode(EmptyParam postalCode) { + this.postalCode = postalCode; + return this; + } - public static Builder builder() { - return new Builder(); - } + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(String state) { + this.state = state; + return this; + } - public static class Builder { - private Object accountFunding; + /** + * State, county, province, or region (ISO 3166-2). + */ + public Builder setState(EmptyParam state) { + this.state = state; + return this; + } + } + } - private Map extraParams; + @Getter + @EqualsAndHashCode(callSuper = false) + public static class DateOfBirth { + /** Required. Day of birth, between 1 and 31. */ + @SerializedName("day") + Long day; - private TransactionType transactionType; + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} + * value. Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.MoneyServices build() { - return new PaymentIntentUpdateParams.PaymentDetails.MoneyServices( - this.accountFunding, this.extraParams, this.transactionType); - } + /** Required. Month of birth, between 1 and 12. */ + @SerializedName("month") + Long month; - /** Account funding transaction details including sender and beneficiary information. */ - public Builder setAccountFunding( - PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { - this.accountFunding = accountFunding; - return this; - } + /** Required. Four-digit year of birth. */ + @SerializedName("year") + Long year; - /** Account funding transaction details including sender and beneficiary information. */ - public Builder setAccountFunding(EmptyParam accountFunding) { - this.accountFunding = accountFunding; - return this; - } + private DateOfBirth(Long day, Map extraParams, Long month, Long year) { + this.day = day; + this.extraParams = extraParams; + this.month = month; + this.year = year; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.MoneyServices#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + public static Builder builder() { + return new Builder(); + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link PaymentIntentUpdateParams.PaymentDetails.MoneyServices#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } + public static class Builder { + private Long day; - /** The type of money services transaction. */ - public Builder setTransactionType( - PaymentIntentUpdateParams.PaymentDetails.MoneyServices.TransactionType - transactionType) { - this.transactionType = transactionType; - return this; - } - } + private Map extraParams; - @Getter - @EqualsAndHashCode(callSuper = false) - public static class AccountFunding { - /** - * Map of extra parameters for custom features not available in this client library. The - * content in this map is not serialized under this field's {@code @SerializedName} value. - * Instead, each key/value pair is serialized as if the key is a root-level field - * (serialized) name in this param object. Effectively, this map is flattened to its parent - * instance. - */ - @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) - Map extraParams; + private Long month; - private AccountFunding(Map extraParams) { - this.extraParams = extraParams; - } + private Long year; - public static Builder builder() { - return new Builder(); - } + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.DateOfBirth + build() { + return new PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding + .SenderDetails.DateOfBirth(this.day, this.extraParams, this.month, this.year); + } - public static class Builder { - private Map extraParams; + /** Required. Day of birth, between 1 and 31. */ + public Builder setDay(Long day) { + this.day = day; + return this; + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding build() { - return new PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding( - this.extraParams); - } + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for - * the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.put(key, value); - return this; - } + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding.SenderDetails.DateOfBirth#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the original - * map. See {@link - * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** Required. Month of birth, between 1 and 12. */ + public Builder setMonth(Long month) { + this.month = month; + return this; + } + + /** Required. Four-digit year of birth. */ + public Builder setYear(Long year) { + this.year = year; + return this; + } } - this.extraParams.putAll(map); - return this; } } } @@ -27996,53 +30476,628 @@ public static class AccountFunding { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private AccountFunding(Map extraParams) { + /** Details for a liquid asset (crypto or security) funding transaction. */ + @SerializedName("liquid_asset") + Object liquidAsset; + + /** Details for a wallet funding transaction. */ + @SerializedName("wallet") + Wallet wallet; + + private AccountFunding( + Map extraParams, Object liquidAsset, Wallet wallet) { this.extraParams = extraParams; + this.liquidAsset = liquidAsset; + this.wallet = wallet; } public static Builder builder() { return new Builder(); } - public static class Builder { - private Map extraParams; + public static class Builder { + private Map extraParams; + + private Object liquidAsset; + + private Wallet wallet; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding(this.extraParams, this.liquidAsset, this.wallet); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Details for a liquid asset (crypto or security) funding transaction. */ + public Builder setLiquidAsset( + PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + .AccountFunding.LiquidAsset + liquidAsset) { + this.liquidAsset = liquidAsset; + return this; + } + + /** Details for a liquid asset (crypto or security) funding transaction. */ + public Builder setLiquidAsset(EmptyParam liquidAsset) { + this.liquidAsset = liquidAsset; + return this; + } + + /** Details for a wallet funding transaction. */ + public Builder setWallet( + PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + .AccountFunding.Wallet + wallet) { + this.wallet = wallet; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class LiquidAsset { + /** Details for a cryptocurrency liquid asset funding transaction. */ + @SerializedName("crypto") + Crypto crypto; + + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if the + * key is a root-level field (serialized) name in this param object. Effectively, this + * map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Details for a security liquid asset funding transaction. */ + @SerializedName("security") + Security security; + + private LiquidAsset( + Crypto crypto, Map extraParams, Security security) { + this.crypto = crypto; + this.extraParams = extraParams; + this.security = security; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Crypto crypto; + + private Map extraParams; + + private Security security; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset( + this.crypto, this.extraParams, this.security); + } + + /** Details for a cryptocurrency liquid asset funding transaction. */ + public Builder setCrypto( + PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + .AccountFunding.LiquidAsset.Crypto + crypto) { + this.crypto = crypto; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Details for a security liquid asset funding transaction. */ + public Builder setSecurity( + PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + .AccountFunding.LiquidAsset.Security + security) { + this.security = security; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Crypto { + /** The cryptocurrency currency code (e.g. BTC, ETH). */ + @SerializedName("currency_code") + Object currencyCode; + + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Crypto(Object currencyCode, Map extraParams) { + this.currencyCode = currencyCode; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object currencyCode; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Crypto + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Crypto( + this.currencyCode, this.extraParams); + } + + /** The cryptocurrency currency code (e.g. BTC, ETH). */ + public Builder setCurrencyCode(String currencyCode) { + this.currencyCode = currencyCode; + return this; + } + + /** The cryptocurrency currency code (e.g. BTC, ETH). */ + public Builder setCurrencyCode(EmptyParam currencyCode) { + this.currencyCode = currencyCode; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Crypto#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Crypto#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Security { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The security's ticker symbol (e.g. AAPL). */ + @SerializedName("ticker_symbol") + Object tickerSymbol; + + private Security(Map extraParams, Object tickerSymbol) { + this.extraParams = extraParams; + this.tickerSymbol = tickerSymbol; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Object tickerSymbol; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Security + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Security( + this.extraParams, this.tickerSymbol); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Security#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Security#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The security's ticker symbol (e.g. AAPL). */ + public Builder setTickerSymbol(String tickerSymbol) { + this.tickerSymbol = tickerSymbol; + return this; + } + + /** The security's ticker symbol (e.g. AAPL). */ + public Builder setTickerSymbol(EmptyParam tickerSymbol) { + this.tickerSymbol = tickerSymbol; + return this; + } + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Wallet { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if the + * key is a root-level field (serialized) name in this param object. Effectively, this + * map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Details for a staged purchase. */ + @SerializedName("staged_purchase") + Object stagedPurchase; + + private Wallet(Map extraParams, Object stagedPurchase) { + this.extraParams = extraParams; + this.stagedPurchase = stagedPurchase; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Object stagedPurchase; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet(this.extraParams, this.stagedPurchase); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Details for a staged purchase. */ + public Builder setStagedPurchase( + PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + .AccountFunding.Wallet.StagedPurchase + stagedPurchase) { + this.stagedPurchase = stagedPurchase; + return this; + } + + /** Details for a staged purchase. */ + public Builder setStagedPurchase(EmptyParam stagedPurchase) { + this.stagedPurchase = stagedPurchase; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class StagedPurchase { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The merchant where the staged wallet purchase is made. */ + @SerializedName("merchant") + Merchant merchant; + + private StagedPurchase(Map extraParams, Merchant merchant) { + this.extraParams = extraParams; + this.merchant = merchant; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Merchant merchant; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase( + this.extraParams, this.merchant); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } - /** Finalize and obtain parameter instance from this builder. */ - public PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails - .MoneyServices.AccountFunding - build() { - return new PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails - .MoneyServices.AccountFunding(this.extraParams); - } + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } - /** - * Add a key/value pair to `extraParams` map. A map is initialized for the first - * `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#extraParams} - * for the field documentation. - */ - public Builder putExtraParam(String key, Object value) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + /** The merchant where the staged wallet purchase is made. */ + public Builder setMerchant( + PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant + merchant) { + this.merchant = merchant; + return this; + } } - this.extraParams.put(key, value); - return this; - } - /** - * Add all map key/value pairs to `extraParams` map. A map is initialized for the - * first `put/putAll` call, and subsequent calls add additional key/value pairs to the - * original map. See {@link - * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#extraParams} - * for the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Merchant { + /** + * Map of extra parameters for custom features not available in this client + * library. The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The merchant category code of the merchant. */ + @SerializedName("mcc") + Object mcc; + + /** The merchant's name. */ + @SerializedName("name") + Object name; + + private Merchant(Map extraParams, Object mcc, Object name) { + this.extraParams = extraParams; + this.mcc = mcc; + this.name = name; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Object mcc; + + private Object name; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant( + this.extraParams, this.mcc, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for + * the first `put/putAll` call, and subsequent calls add additional key/value + * pairs to the original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The merchant category code of the merchant. */ + public Builder setMcc(String mcc) { + this.mcc = mcc; + return this; + } + + /** The merchant category code of the merchant. */ + public Builder setMcc(EmptyParam mcc) { + this.mcc = mcc; + return this; + } + + /** The merchant's name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** The merchant's name. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } + } } - this.extraParams.putAll(map); - return this; } } } @@ -29536,8 +32591,19 @@ public static class AccountFunding { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; - private AccountFunding(Map extraParams) { + /** Details for a liquid asset (crypto or security) funding transaction. */ + @SerializedName("liquid_asset") + Object liquidAsset; + + /** Details for a wallet funding transaction. */ + @SerializedName("wallet") + Wallet wallet; + + private AccountFunding( + Map extraParams, Object liquidAsset, Wallet wallet) { this.extraParams = extraParams; + this.liquidAsset = liquidAsset; + this.wallet = wallet; } public static Builder builder() { @@ -29547,12 +32613,16 @@ public static Builder builder() { public static class Builder { private Map extraParams; + private Object liquidAsset; + + private Wallet wallet; + /** Finalize and obtain parameter instance from this builder. */ public PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails .MoneyServices.AccountFunding build() { return new PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails - .MoneyServices.AccountFunding(this.extraParams); + .MoneyServices.AccountFunding(this.extraParams, this.liquidAsset, this.wallet); } /** @@ -29584,6 +32654,567 @@ public Builder putAllExtraParam(Map map) { this.extraParams.putAll(map); return this; } + + /** Details for a liquid asset (crypto or security) funding transaction. */ + public Builder setLiquidAsset( + PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset + liquidAsset) { + this.liquidAsset = liquidAsset; + return this; + } + + /** Details for a liquid asset (crypto or security) funding transaction. */ + public Builder setLiquidAsset(EmptyParam liquidAsset) { + this.liquidAsset = liquidAsset; + return this; + } + + /** Details for a wallet funding transaction. */ + public Builder setWallet( + PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet + wallet) { + this.wallet = wallet; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class LiquidAsset { + /** Details for a cryptocurrency liquid asset funding transaction. */ + @SerializedName("crypto") + Crypto crypto; + + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if the + * key is a root-level field (serialized) name in this param object. Effectively, this + * map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Details for a security liquid asset funding transaction. */ + @SerializedName("security") + Security security; + + private LiquidAsset( + Crypto crypto, Map extraParams, Security security) { + this.crypto = crypto; + this.extraParams = extraParams; + this.security = security; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Crypto crypto; + + private Map extraParams; + + private Security security; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.LiquidAsset( + this.crypto, this.extraParams, this.security); + } + + /** Details for a cryptocurrency liquid asset funding transaction. */ + public Builder setCrypto( + PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Crypto + crypto) { + this.crypto = crypto; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Details for a security liquid asset funding transaction. */ + public Builder setSecurity( + PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Security + security) { + this.security = security; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Crypto { + /** The cryptocurrency currency code (e.g. BTC, ETH). */ + @SerializedName("currency_code") + Object currencyCode; + + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private Crypto(Object currencyCode, Map extraParams) { + this.currencyCode = currencyCode; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object currencyCode; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Crypto + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Crypto( + this.currencyCode, this.extraParams); + } + + /** The cryptocurrency currency code (e.g. BTC, ETH). */ + public Builder setCurrencyCode(String currencyCode) { + this.currencyCode = currencyCode; + return this; + } + + /** The cryptocurrency currency code (e.g. BTC, ETH). */ + public Builder setCurrencyCode(EmptyParam currencyCode) { + this.currencyCode = currencyCode; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Crypto#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Crypto#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Security { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The security's ticker symbol (e.g. AAPL). */ + @SerializedName("ticker_symbol") + Object tickerSymbol; + + private Security(Map extraParams, Object tickerSymbol) { + this.extraParams = extraParams; + this.tickerSymbol = tickerSymbol; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Object tickerSymbol; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.LiquidAsset.Security + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Security( + this.extraParams, this.tickerSymbol); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Security#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.LiquidAsset.Security#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The security's ticker symbol (e.g. AAPL). */ + public Builder setTickerSymbol(String tickerSymbol) { + this.tickerSymbol = tickerSymbol; + return this; + } + + /** The security's ticker symbol (e.g. AAPL). */ + public Builder setTickerSymbol(EmptyParam tickerSymbol) { + this.tickerSymbol = tickerSymbol; + return this; + } + } + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Wallet { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if the + * key is a root-level field (serialized) name in this param object. Effectively, this + * map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Details for a staged purchase. */ + @SerializedName("staged_purchase") + Object stagedPurchase; + + private Wallet(Map extraParams, Object stagedPurchase) { + this.extraParams = extraParams; + this.stagedPurchase = stagedPurchase; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Object stagedPurchase; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.Wallet( + this.extraParams, this.stagedPurchase); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Details for a staged purchase. */ + public Builder setStagedPurchase( + PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase + stagedPurchase) { + this.stagedPurchase = stagedPurchase; + return this; + } + + /** Details for a staged purchase. */ + public Builder setStagedPurchase(EmptyParam stagedPurchase) { + this.stagedPurchase = stagedPurchase; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class StagedPurchase { + /** + * Map of extra parameters for custom features not available in this client library. + * The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The merchant where the staged wallet purchase is made. */ + @SerializedName("merchant") + Merchant merchant; + + private StagedPurchase(Map extraParams, Merchant merchant) { + this.extraParams = extraParams; + this.merchant = merchant; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Merchant merchant; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase( + this.extraParams, this.merchant); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the + * first `put/putAll` call, and subsequent calls add additional key/value pairs to + * the original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The merchant where the staged wallet purchase is made. */ + public Builder setMerchant( + PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant + merchant) { + this.merchant = merchant; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Merchant { + /** + * Map of extra parameters for custom features not available in this client + * library. The content in this map is not serialized under this field's + * {@code @SerializedName} value. Instead, each key/value pair is serialized as if + * the key is a root-level field (serialized) name in this param object. + * Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** The merchant category code of the merchant. */ + @SerializedName("mcc") + Object mcc; + + /** The merchant's name. */ + @SerializedName("name") + Object name; + + private Merchant(Map extraParams, Object mcc, Object name) { + this.extraParams = extraParams; + this.mcc = mcc; + this.name = name; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Object mcc; + + private Object name; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase + .Merchant(this.extraParams, this.mcc, this.name); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for + * the first `put/putAll` call, and subsequent calls add additional key/value + * pairs to the original map. See {@link + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding.Wallet.StagedPurchase.Merchant#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** The merchant category code of the merchant. */ + public Builder setMcc(String mcc) { + this.mcc = mcc; + return this; + } + + /** The merchant category code of the merchant. */ + public Builder setMcc(EmptyParam mcc) { + this.mcc = mcc; + return this; + } + + /** The merchant's name. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + /** The merchant's name. */ + public Builder setName(EmptyParam name) { + this.name = name; + return this; + } + } + } + } } } } diff --git a/src/main/java/com/stripe/param/SubscriptionCreateParams.java b/src/main/java/com/stripe/param/SubscriptionCreateParams.java index 5bf3e609efe..47cbc963942 100644 --- a/src/main/java/com/stripe/param/SubscriptionCreateParams.java +++ b/src/main/java/com/stripe/param/SubscriptionCreateParams.java @@ -6344,6 +6344,13 @@ public static class PaymentMethodOptions { @SerializedName("bancontact") Object bancontact; + /** + * This sub-hash contains details about the Bizum payment method options to pass to the + * invoice’s PaymentIntent. + */ + @SerializedName("bizum") + Object bizum; + /** * This sub-hash contains details about the Card payment method options to pass to the * invoice’s PaymentIntent. @@ -6426,6 +6433,7 @@ public static class PaymentMethodOptions { private PaymentMethodOptions( Object acssDebit, Object bancontact, + Object bizum, Object card, Object checkScan, Object customerBalance, @@ -6439,6 +6447,7 @@ private PaymentMethodOptions( Object usBankAccount) { this.acssDebit = acssDebit; this.bancontact = bancontact; + this.bizum = bizum; this.card = card; this.checkScan = checkScan; this.customerBalance = customerBalance; @@ -6461,6 +6470,8 @@ public static class Builder { private Object bancontact; + private Object bizum; + private Object card; private Object checkScan; @@ -6488,6 +6499,7 @@ public SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions build() { return new SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions( this.acssDebit, this.bancontact, + this.bizum, this.card, this.checkScan, this.customerBalance, @@ -6539,6 +6551,25 @@ public Builder setBancontact(EmptyParam bancontact) { return this; } + /** + * This sub-hash contains details about the Bizum payment method options to pass to the + * invoice’s PaymentIntent. + */ + public Builder setBizum( + SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.Bizum bizum) { + this.bizum = bizum; + return this; + } + + /** + * This sub-hash contains details about the Bizum payment method options to pass to the + * invoice’s PaymentIntent. + */ + public Builder setBizum(EmptyParam bizum) { + this.bizum = bizum; + return this; + } + /** * This sub-hash contains details about the Card payment method options to pass to the * invoice’s PaymentIntent. @@ -7077,6 +7108,195 @@ public enum PreferredLanguage implements ApiRequestParams.EnumParam { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Bizum { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Configuration options for setting up a mandate. */ + @SerializedName("mandate_options") + MandateOptions mandateOptions; + + private Bizum(Map extraParams, MandateOptions mandateOptions) { + this.extraParams = extraParams; + this.mandateOptions = mandateOptions; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private MandateOptions mandateOptions; + + /** Finalize and obtain parameter instance from this builder. */ + public SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.Bizum build() { + return new SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.Bizum( + this.extraParams, this.mandateOptions); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.Bizum#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.Bizum#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Configuration options for setting up a mandate. */ + public Builder setMandateOptions( + SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.Bizum.MandateOptions + mandateOptions) { + this.mandateOptions = mandateOptions; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MandateOptions { + /** + * Required. Amount to be charged for future payments. Required when + * {@code amount_type=fixed}. + */ + @SerializedName("amount") + Long amount; + + /** Required. Indicates the mandate amount type. */ + @SerializedName("amount_type") + AmountType amountType; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private MandateOptions( + Long amount, AmountType amountType, Map extraParams) { + this.amount = amount; + this.amountType = amountType; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private AmountType amountType; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.Bizum + .MandateOptions + build() { + return new SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.Bizum + .MandateOptions(this.amount, this.amountType, this.extraParams); + } + + /** + * Required. Amount to be charged for future payments. Required when + * {@code amount_type=fixed}. + */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Required. Indicates the mandate amount type. */ + public Builder setAmountType( + SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.Bizum.MandateOptions + .AmountType + amountType) { + this.amountType = amountType; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.Bizum.MandateOptions#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.Bizum.MandateOptions#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + + public enum AmountType implements ApiRequestParams.EnumParam { + @SerializedName("fixed") + FIXED("fixed"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + AmountType(String value) { + this.value = value; + } + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class Card { @@ -9380,6 +9600,9 @@ public enum PaymentMethodType implements ApiRequestParams.EnumParam { @SerializedName("bancontact") BANCONTACT("bancontact"), + @SerializedName("bizum") + BIZUM("bizum"), + @SerializedName("boleto") BOLETO("boleto"), diff --git a/src/main/java/com/stripe/param/SubscriptionUpdateParams.java b/src/main/java/com/stripe/param/SubscriptionUpdateParams.java index c1e8b19545f..bf91c1ba478 100644 --- a/src/main/java/com/stripe/param/SubscriptionUpdateParams.java +++ b/src/main/java/com/stripe/param/SubscriptionUpdateParams.java @@ -6420,6 +6420,13 @@ public static class PaymentMethodOptions { @SerializedName("bancontact") Object bancontact; + /** + * This sub-hash contains details about the Bizum payment method options to pass to the + * invoice’s PaymentIntent. + */ + @SerializedName("bizum") + Object bizum; + /** * This sub-hash contains details about the Card payment method options to pass to the * invoice’s PaymentIntent. @@ -6502,6 +6509,7 @@ public static class PaymentMethodOptions { private PaymentMethodOptions( Object acssDebit, Object bancontact, + Object bizum, Object card, Object checkScan, Object customerBalance, @@ -6515,6 +6523,7 @@ private PaymentMethodOptions( Object usBankAccount) { this.acssDebit = acssDebit; this.bancontact = bancontact; + this.bizum = bizum; this.card = card; this.checkScan = checkScan; this.customerBalance = customerBalance; @@ -6537,6 +6546,8 @@ public static class Builder { private Object bancontact; + private Object bizum; + private Object card; private Object checkScan; @@ -6564,6 +6575,7 @@ public SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions build() { return new SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions( this.acssDebit, this.bancontact, + this.bizum, this.card, this.checkScan, this.customerBalance, @@ -6615,6 +6627,25 @@ public Builder setBancontact(EmptyParam bancontact) { return this; } + /** + * This sub-hash contains details about the Bizum payment method options to pass to the + * invoice’s PaymentIntent. + */ + public Builder setBizum( + SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.Bizum bizum) { + this.bizum = bizum; + return this; + } + + /** + * This sub-hash contains details about the Bizum payment method options to pass to the + * invoice’s PaymentIntent. + */ + public Builder setBizum(EmptyParam bizum) { + this.bizum = bizum; + return this; + } + /** * This sub-hash contains details about the Card payment method options to pass to the * invoice’s PaymentIntent. @@ -7153,6 +7184,195 @@ public enum PreferredLanguage implements ApiRequestParams.EnumParam { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Bizum { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its parent + * instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Configuration options for setting up a mandate. */ + @SerializedName("mandate_options") + MandateOptions mandateOptions; + + private Bizum(Map extraParams, MandateOptions mandateOptions) { + this.extraParams = extraParams; + this.mandateOptions = mandateOptions; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private MandateOptions mandateOptions; + + /** Finalize and obtain parameter instance from this builder. */ + public SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.Bizum build() { + return new SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.Bizum( + this.extraParams, this.mandateOptions); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.Bizum#extraParams} for + * the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.Bizum#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Configuration options for setting up a mandate. */ + public Builder setMandateOptions( + SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.Bizum.MandateOptions + mandateOptions) { + this.mandateOptions = mandateOptions; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MandateOptions { + /** + * Required. Amount to be charged for future payments. Required when + * {@code amount_type=fixed}. + */ + @SerializedName("amount") + Long amount; + + /** Required. Indicates the mandate amount type. */ + @SerializedName("amount_type") + AmountType amountType; + + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field + * (serialized) name in this param object. Effectively, this map is flattened to its + * parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + private MandateOptions( + Long amount, AmountType amountType, Map extraParams) { + this.amount = amount; + this.amountType = amountType; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Long amount; + + private AmountType amountType; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.Bizum + .MandateOptions + build() { + return new SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.Bizum + .MandateOptions(this.amount, this.amountType, this.extraParams); + } + + /** + * Required. Amount to be charged for future payments. Required when + * {@code amount_type=fixed}. + */ + public Builder setAmount(Long amount) { + this.amount = amount; + return this; + } + + /** Required. Indicates the mandate amount type. */ + public Builder setAmountType( + SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.Bizum.MandateOptions + .AmountType + amountType) { + this.amountType = amountType; + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.Bizum.MandateOptions#extraParams} + * for the field documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the + * original map. See {@link + * SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.Bizum.MandateOptions#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + + public enum AmountType implements ApiRequestParams.EnumParam { + @SerializedName("fixed") + FIXED("fixed"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + AmountType(String value) { + this.value = value; + } + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class Card { @@ -9548,6 +9768,9 @@ public enum PaymentMethodType implements ApiRequestParams.EnumParam { @SerializedName("bancontact") BANCONTACT("bancontact"), + @SerializedName("bizum") + BIZUM("bizum"), + @SerializedName("boleto") BOLETO("boleto"), diff --git a/src/main/java/com/stripe/param/radar/CustomerEvaluationCreateParams.java b/src/main/java/com/stripe/param/radar/CustomerEvaluationCreateParams.java index a1cec0742c5..9be070024de 100644 --- a/src/main/java/com/stripe/param/radar/CustomerEvaluationCreateParams.java +++ b/src/main/java/com/stripe/param/radar/CustomerEvaluationCreateParams.java @@ -335,7 +335,7 @@ public Builder setRadarSession(String radarSession) { @Getter @EqualsAndHashCode(callSuper = false) public static class CustomerDetails { - /** Stripe customer ID. */ + /** The ID of an existing Customer. */ @SerializedName("customer") String customer; @@ -376,7 +376,7 @@ public CustomerEvaluationCreateParams.EvaluationContext.CustomerDetails build() this.customer, this.customerData, this.extraParams); } - /** Stripe customer ID. */ + /** The ID of an existing Customer. */ public Builder setCustomer(String customer) { this.customer = customer; return this; diff --git a/src/main/java/com/stripe/param/radar/CustomerEvaluationUpdateParams.java b/src/main/java/com/stripe/param/radar/CustomerEvaluationUpdateParams.java index ed05bcc6ccf..764789891e3 100644 --- a/src/main/java/com/stripe/param/radar/CustomerEvaluationUpdateParams.java +++ b/src/main/java/com/stripe/param/radar/CustomerEvaluationUpdateParams.java @@ -338,7 +338,7 @@ public enum Reason implements ApiRequestParams.EnumParam { @Getter @EqualsAndHashCode(callSuper = false) public static class RegistrationSuccess { - /** Stripe customer ID to attach to an entity-less registration evaluation. */ + /** The ID of a Customer to attach to an entity-less registration evaluation. */ @SerializedName("customer") Object customer; @@ -371,13 +371,13 @@ public CustomerEvaluationUpdateParams.RegistrationSuccess build() { this.customer, this.extraParams); } - /** Stripe customer ID to attach to an entity-less registration evaluation. */ + /** The ID of a Customer to attach to an entity-less registration evaluation. */ public Builder setCustomer(String customer) { this.customer = customer; return this; } - /** Stripe customer ID to attach to an entity-less registration evaluation. */ + /** The ID of a Customer to attach to an entity-less registration evaluation. */ public Builder setCustomer(EmptyParam customer) { this.customer = customer; return this; diff --git a/src/main/java/com/stripe/param/radar/PaymentEvaluationCreateParams.java b/src/main/java/com/stripe/param/radar/PaymentEvaluationCreateParams.java index d9072f65bdf..521bb850225 100644 --- a/src/main/java/com/stripe/param/radar/PaymentEvaluationCreateParams.java +++ b/src/main/java/com/stripe/param/radar/PaymentEvaluationCreateParams.java @@ -196,6 +196,13 @@ public Builder setPaymentDetails(PaymentEvaluationCreateParams.PaymentDetails pa @Getter @EqualsAndHashCode(callSuper = false) public static class ClientDeviceMetadataDetails { + /** + * Direct client device attributes such as IP address and user agent. Use this as an alternative + * to radar_session when a Radar Session isn't available. + */ + @SerializedName("data") + Data data; + /** * Map of extra parameters for custom features not available in this client library. The content * in this map is not serialized under this field's {@code @SerializedName} value. Instead, each @@ -214,7 +221,9 @@ public static class ClientDeviceMetadataDetails { @SerializedName("radar_session") String radarSession; - private ClientDeviceMetadataDetails(Map extraParams, String radarSession) { + private ClientDeviceMetadataDetails( + Data data, Map extraParams, String radarSession) { + this.data = data; this.extraParams = extraParams; this.radarSession = radarSession; } @@ -224,6 +233,8 @@ public static Builder builder() { } public static class Builder { + private Data data; + private Map extraParams; private String radarSession; @@ -231,7 +242,16 @@ public static class Builder { /** Finalize and obtain parameter instance from this builder. */ public PaymentEvaluationCreateParams.ClientDeviceMetadataDetails build() { return new PaymentEvaluationCreateParams.ClientDeviceMetadataDetails( - this.extraParams, this.radarSession); + this.data, this.extraParams, this.radarSession); + } + + /** + * Direct client device attributes such as IP address and user agent. Use this as an + * alternative to radar_session when a Radar Session isn't available. + */ + public Builder setData(PaymentEvaluationCreateParams.ClientDeviceMetadataDetails.Data data) { + this.data = data; + return this; } /** @@ -273,6 +293,191 @@ public Builder setRadarSession(String radarSession) { return this; } } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Data { + /** + * Map of extra parameters for custom features not available in this client library. The + * content in this map is not serialized under this field's {@code @SerializedName} value. + * Instead, each key/value pair is serialized as if the key is a root-level field (serialized) + * name in this param object. Effectively, this map is flattened to its parent instance. + */ + @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) + Map extraParams; + + /** Required. The IP address of the client device. */ + @SerializedName("ip") + String ip; + + /** Pasted fields from the checkout flow. */ + @SerializedName("pasted_fields") + List pastedFields; + + /** The referrer of the client device. */ + @SerializedName("referrer") + String referrer; + + /** The time on page in milliseconds. */ + @SerializedName("time_on_page_ms") + Long timeOnPageMs; + + /** Required. The user agent of the client device. */ + @SerializedName("user_agent") + String userAgent; + + private Data( + Map extraParams, + String ip, + List + pastedFields, + String referrer, + Long timeOnPageMs, + String userAgent) { + this.extraParams = extraParams; + this.ip = ip; + this.pastedFields = pastedFields; + this.referrer = referrer; + this.timeOnPageMs = timeOnPageMs; + this.userAgent = userAgent; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String ip; + + private List + pastedFields; + + private String referrer; + + private Long timeOnPageMs; + + private String userAgent; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentEvaluationCreateParams.ClientDeviceMetadataDetails.Data build() { + return new PaymentEvaluationCreateParams.ClientDeviceMetadataDetails.Data( + this.extraParams, + this.ip, + this.pastedFields, + this.referrer, + this.timeOnPageMs, + this.userAgent); + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentEvaluationCreateParams.ClientDeviceMetadataDetails.Data#extraParams} for the field + * documentation. + */ + public Builder putExtraParam(String key, Object value) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.put(key, value); + return this; + } + + /** + * Add all map key/value pairs to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link + * PaymentEvaluationCreateParams.ClientDeviceMetadataDetails.Data#extraParams} for the field + * documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Required. The IP address of the client device. */ + public Builder setIp(String ip) { + this.ip = ip; + return this; + } + + /** + * Add an element to `pastedFields` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentEvaluationCreateParams.ClientDeviceMetadataDetails.Data#pastedFields} for the + * field documentation. + */ + public Builder addPastedField( + PaymentEvaluationCreateParams.ClientDeviceMetadataDetails.Data.PastedField element) { + if (this.pastedFields == null) { + this.pastedFields = new ArrayList<>(); + } + this.pastedFields.add(element); + return this; + } + + /** + * Add all elements to `pastedFields` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * PaymentEvaluationCreateParams.ClientDeviceMetadataDetails.Data#pastedFields} for the + * field documentation. + */ + public Builder addAllPastedField( + List + elements) { + if (this.pastedFields == null) { + this.pastedFields = new ArrayList<>(); + } + this.pastedFields.addAll(elements); + return this; + } + + /** The referrer of the client device. */ + public Builder setReferrer(String referrer) { + this.referrer = referrer; + return this; + } + + /** The time on page in milliseconds. */ + public Builder setTimeOnPageMs(Long timeOnPageMs) { + this.timeOnPageMs = timeOnPageMs; + return this; + } + + /** Required. The user agent of the client device. */ + public Builder setUserAgent(String userAgent) { + this.userAgent = userAgent; + return this; + } + } + + public enum PastedField implements ApiRequestParams.EnumParam { + @SerializedName("cvc") + CVC("cvc"), + + @SerializedName("exp") + EXP("exp"), + + @SerializedName("number") + NUMBER("number"), + + @SerializedName("zip") + ZIP("zip"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + PastedField(String value) { + this.value = value; + } + } + } } @Getter diff --git a/src/main/java/com/stripe/param/v2/core/AccountCreateParams.java b/src/main/java/com/stripe/param/v2/core/AccountCreateParams.java index 0cd6fcf0b2f..3a445207e0b 100644 --- a/src/main/java/com/stripe/param/v2/core/AccountCreateParams.java +++ b/src/main/java/com/stripe/param/v2/core/AccountCreateParams.java @@ -25434,18 +25434,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_vat") BG_VAT("bg_vat"), - @SerializedName("bm_crn") - BM_CRN("bm_crn"), - - @SerializedName("bo_tin") - BO_TIN("bo_tin"), - @SerializedName("br_cnpj") BR_CNPJ("br_cnpj"), - @SerializedName("bt_tpn") - BT_TPN("bt_tpn"), - @SerializedName("ca_cn") CA_CN("ca_cn"), @@ -25467,9 +25458,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ch_uid") CH_UID("ch_uid"), - @SerializedName("co_nit") - CO_NIT("co_nit"), - @SerializedName("cr_cpj") CR_CPJ("cr_cpj"), @@ -25509,18 +25497,12 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("do_rcn") DO_RCN("do_rcn"), - @SerializedName("ec_ruc") - EC_RUC("ec_ruc"), - @SerializedName("ee_rk") EE_RK("ee_rk"), @SerializedName("ee_vat") EE_VAT("ee_vat"), - @SerializedName("eg_tin") - EG_TIN("eg_tin"), - @SerializedName("es_cif") ES_CIF("es_cif"), @@ -25548,9 +25530,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_vat") GB_VAT("gb_vat"), - @SerializedName("gh_tin") - GH_TIN("gh_tin"), - @SerializedName("gi_crn") GI_CRN("gi_crn"), @@ -25566,18 +25545,12 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gt_nit") GT_NIT("gt_nit"), - @SerializedName("gy_tin") - GY_TIN("gy_tin"), - @SerializedName("hk_br") HK_BR("hk_br"), @SerializedName("hk_cr") HK_CR("hk_cr"), - @SerializedName("hn_rtn") - HN_RTN("hn_rtn"), - @SerializedName("hr_mbs") HR_MBS("hr_mbs"), @@ -25611,30 +25584,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_vat") IT_VAT("it_vat"), - @SerializedName("jm_trn") - JM_TRN("jm_trn"), - - @SerializedName("jo_crn") - JO_CRN("jo_crn"), - @SerializedName("jp_cn") JP_CN("jp_cn"), - @SerializedName("ke_pin") - KE_PIN("ke_pin"), - - @SerializedName("ky_crn") - KY_CRN("ky_crn"), - @SerializedName("kz_bin") KZ_BIN("kz_bin"), @SerializedName("li_uid") LI_UID("li_uid"), - @SerializedName("lk_tin") - LK_TIN("lk_tin"), - @SerializedName("lt_ccrn") LT_CCRN("lt_ccrn"), @@ -25656,9 +25614,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_vat") LV_VAT("lv_vat"), - @SerializedName("mo_tin") - MO_TIN("mo_tin"), - @SerializedName("mt_crn") MT_CRN("mt_crn"), @@ -25668,9 +25623,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("mt_vat") MT_VAT("mt_vat"), - @SerializedName("mv_tin") - MV_TIN("mv_tin"), - @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -25689,9 +25641,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("mz_nuit") MZ_NUIT("mz_nuit"), - @SerializedName("ng_tin") - NG_TIN("ng_tin"), - @SerializedName("nl_kvk") NL_KVK("nl_kvk"), @@ -25710,15 +25659,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), - @SerializedName("pa_ruc") - PA_RUC("pa_ruc"), - @SerializedName("pe_ruc") PE_RUC("pe_ruc"), - @SerializedName("ph_tin") - PH_TIN("ph_tin"), - @SerializedName("pk_ntn") PK_NTN("pk_ntn"), @@ -25734,9 +25677,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_vat") PT_VAT("pt_vat"), - @SerializedName("py_ruc") - PY_RUC("py_ruc"), - @SerializedName("ro_cui") RO_CUI("ro_cui"), @@ -25779,12 +25719,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sk_vat") SK_VAT("sk_vat"), - @SerializedName("sl_tin") - SL_TIN("sl_tin"), - - @SerializedName("sv_nit") - SV_NIT("sv_nit"), - @SerializedName("th_crn") TH_CRN("th_crn"), @@ -25795,16 +25729,7 @@ public enum Type implements ApiRequestParams.EnumParam { TH_TIN("th_tin"), @SerializedName("us_ein") - US_EIN("us_ein"), - - @SerializedName("uy_ruc") - UY_RUC("uy_ruc"), - - @SerializedName("vg_cn") - VG_CN("vg_cn"), - - @SerializedName("za_tin") - ZA_TIN("za_tin"); + US_EIN("us_ein"); @Getter(onMethod_ = {@Override}) private final String value; @@ -28958,21 +28883,12 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_ucn") BG_UCN("bg_ucn"), - @SerializedName("bm_pp") - BM_PP("bm_pp"), - @SerializedName("bn_nric") BN_NRIC("bn_nric"), - @SerializedName("bo_ci") - BO_CI("bo_ci"), - @SerializedName("br_cpf") BR_CPF("br_cpf"), - @SerializedName("bt_cid") - BT_CID("bt_cid"), - @SerializedName("ca_sin") CA_SIN("ca_sin"), @@ -29024,9 +28940,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ee_ik") EE_IK("ee_ik"), - @SerializedName("eg_tin") - EG_TIN("eg_tin"), - @SerializedName("es_nif") ES_NIF("es_nif"), @@ -29039,24 +28952,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_nino") GB_NINO("gb_nino"), - @SerializedName("gh_pin") - GH_PIN("gh_pin"), - @SerializedName("gr_afm") GR_AFM("gr_afm"), @SerializedName("gt_nit") GT_NIT("gt_nit"), - @SerializedName("gy_tin") - GY_TIN("gy_tin"), - @SerializedName("hk_id") HK_ID("hk_id"), - @SerializedName("hn_rtn") - HN_RTN("hn_rtn"), - @SerializedName("hr_oib") HR_OIB("hr_oib"), @@ -29075,30 +28979,18 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_cf") IT_CF("it_cf"), - @SerializedName("jm_trn") - JM_TRN("jm_trn"), - - @SerializedName("jo_pin") - JO_PIN("jo_pin"), - @SerializedName("jp_inc") JP_INC("jp_inc"), @SerializedName("ke_pin") KE_PIN("ke_pin"), - @SerializedName("ky_pp") - KY_PP("ky_pp"), - @SerializedName("kz_iin") KZ_IIN("kz_iin"), @SerializedName("li_peid") LI_PEID("li_peid"), - @SerializedName("lk_nic") - LK_NIC("lk_nic"), - @SerializedName("lt_ak") LT_AK("lt_ak"), @@ -29108,15 +29000,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_pk") LV_PK("lv_pk"), - @SerializedName("mo_bir") - MO_BIR("mo_bir"), - - @SerializedName("mt_nic") - MT_NIC("mt_nic"), - - @SerializedName("mv_tin") - MV_TIN("mv_tin"), - @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -29138,15 +29021,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), - @SerializedName("pa_ruc") - PA_RUC("pa_ruc"), - @SerializedName("pe_dni") PE_DNI("pe_dni"), - @SerializedName("ph_tin") - PH_TIN("ph_tin"), - @SerializedName("pk_cnic") PK_CNIC("pk_cnic"), @@ -29159,9 +29036,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_nif") PT_NIF("pt_nif"), - @SerializedName("py_ruc") - PY_RUC("py_ruc"), - @SerializedName("ro_cnp") RO_CNP("ro_cnp"), @@ -29177,15 +29051,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sg_nric") SG_NRIC("sg_nric"), - @SerializedName("si_pin") - SI_PIN("si_pin"), - @SerializedName("sk_dic") SK_DIC("sk_dic"), - @SerializedName("sv_nit") - SV_NIT("sv_nit"), - @SerializedName("th_lc") TH_LC("th_lc"), @@ -29210,9 +29078,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("uy_dni") UY_DNI("uy_dni"), - @SerializedName("vg_pp") - VG_PP("vg_pp"), - @SerializedName("za_id") ZA_ID("za_id"); diff --git a/src/main/java/com/stripe/param/v2/core/AccountTokenCreateParams.java b/src/main/java/com/stripe/param/v2/core/AccountTokenCreateParams.java index 406a28dfa91..ee37187eb92 100644 --- a/src/main/java/com/stripe/param/v2/core/AccountTokenCreateParams.java +++ b/src/main/java/com/stripe/param/v2/core/AccountTokenCreateParams.java @@ -5619,18 +5619,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_vat") BG_VAT("bg_vat"), - @SerializedName("bm_crn") - BM_CRN("bm_crn"), - - @SerializedName("bo_tin") - BO_TIN("bo_tin"), - @SerializedName("br_cnpj") BR_CNPJ("br_cnpj"), - @SerializedName("bt_tpn") - BT_TPN("bt_tpn"), - @SerializedName("ca_cn") CA_CN("ca_cn"), @@ -5652,9 +5643,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ch_uid") CH_UID("ch_uid"), - @SerializedName("co_nit") - CO_NIT("co_nit"), - @SerializedName("cr_cpj") CR_CPJ("cr_cpj"), @@ -5694,18 +5682,12 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("do_rcn") DO_RCN("do_rcn"), - @SerializedName("ec_ruc") - EC_RUC("ec_ruc"), - @SerializedName("ee_rk") EE_RK("ee_rk"), @SerializedName("ee_vat") EE_VAT("ee_vat"), - @SerializedName("eg_tin") - EG_TIN("eg_tin"), - @SerializedName("es_cif") ES_CIF("es_cif"), @@ -5733,9 +5715,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_vat") GB_VAT("gb_vat"), - @SerializedName("gh_tin") - GH_TIN("gh_tin"), - @SerializedName("gi_crn") GI_CRN("gi_crn"), @@ -5751,18 +5730,12 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gt_nit") GT_NIT("gt_nit"), - @SerializedName("gy_tin") - GY_TIN("gy_tin"), - @SerializedName("hk_br") HK_BR("hk_br"), @SerializedName("hk_cr") HK_CR("hk_cr"), - @SerializedName("hn_rtn") - HN_RTN("hn_rtn"), - @SerializedName("hr_mbs") HR_MBS("hr_mbs"), @@ -5796,30 +5769,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_vat") IT_VAT("it_vat"), - @SerializedName("jm_trn") - JM_TRN("jm_trn"), - - @SerializedName("jo_crn") - JO_CRN("jo_crn"), - @SerializedName("jp_cn") JP_CN("jp_cn"), - @SerializedName("ke_pin") - KE_PIN("ke_pin"), - - @SerializedName("ky_crn") - KY_CRN("ky_crn"), - @SerializedName("kz_bin") KZ_BIN("kz_bin"), @SerializedName("li_uid") LI_UID("li_uid"), - @SerializedName("lk_tin") - LK_TIN("lk_tin"), - @SerializedName("lt_ccrn") LT_CCRN("lt_ccrn"), @@ -5841,9 +5799,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_vat") LV_VAT("lv_vat"), - @SerializedName("mo_tin") - MO_TIN("mo_tin"), - @SerializedName("mt_crn") MT_CRN("mt_crn"), @@ -5853,9 +5808,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("mt_vat") MT_VAT("mt_vat"), - @SerializedName("mv_tin") - MV_TIN("mv_tin"), - @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -5874,9 +5826,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("mz_nuit") MZ_NUIT("mz_nuit"), - @SerializedName("ng_tin") - NG_TIN("ng_tin"), - @SerializedName("nl_kvk") NL_KVK("nl_kvk"), @@ -5895,15 +5844,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), - @SerializedName("pa_ruc") - PA_RUC("pa_ruc"), - @SerializedName("pe_ruc") PE_RUC("pe_ruc"), - @SerializedName("ph_tin") - PH_TIN("ph_tin"), - @SerializedName("pk_ntn") PK_NTN("pk_ntn"), @@ -5919,9 +5862,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_vat") PT_VAT("pt_vat"), - @SerializedName("py_ruc") - PY_RUC("py_ruc"), - @SerializedName("ro_cui") RO_CUI("ro_cui"), @@ -5964,12 +5904,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sk_vat") SK_VAT("sk_vat"), - @SerializedName("sl_tin") - SL_TIN("sl_tin"), - - @SerializedName("sv_nit") - SV_NIT("sv_nit"), - @SerializedName("th_crn") TH_CRN("th_crn"), @@ -5980,16 +5914,7 @@ public enum Type implements ApiRequestParams.EnumParam { TH_TIN("th_tin"), @SerializedName("us_ein") - US_EIN("us_ein"), - - @SerializedName("uy_ruc") - UY_RUC("uy_ruc"), - - @SerializedName("vg_cn") - VG_CN("vg_cn"), - - @SerializedName("za_tin") - ZA_TIN("za_tin"); + US_EIN("us_ein"); @Getter(onMethod_ = {@Override}) private final String value; @@ -9176,21 +9101,12 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_ucn") BG_UCN("bg_ucn"), - @SerializedName("bm_pp") - BM_PP("bm_pp"), - @SerializedName("bn_nric") BN_NRIC("bn_nric"), - @SerializedName("bo_ci") - BO_CI("bo_ci"), - @SerializedName("br_cpf") BR_CPF("br_cpf"), - @SerializedName("bt_cid") - BT_CID("bt_cid"), - @SerializedName("ca_sin") CA_SIN("ca_sin"), @@ -9242,9 +9158,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ee_ik") EE_IK("ee_ik"), - @SerializedName("eg_tin") - EG_TIN("eg_tin"), - @SerializedName("es_nif") ES_NIF("es_nif"), @@ -9257,24 +9170,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_nino") GB_NINO("gb_nino"), - @SerializedName("gh_pin") - GH_PIN("gh_pin"), - @SerializedName("gr_afm") GR_AFM("gr_afm"), @SerializedName("gt_nit") GT_NIT("gt_nit"), - @SerializedName("gy_tin") - GY_TIN("gy_tin"), - @SerializedName("hk_id") HK_ID("hk_id"), - @SerializedName("hn_rtn") - HN_RTN("hn_rtn"), - @SerializedName("hr_oib") HR_OIB("hr_oib"), @@ -9293,30 +9197,18 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_cf") IT_CF("it_cf"), - @SerializedName("jm_trn") - JM_TRN("jm_trn"), - - @SerializedName("jo_pin") - JO_PIN("jo_pin"), - @SerializedName("jp_inc") JP_INC("jp_inc"), @SerializedName("ke_pin") KE_PIN("ke_pin"), - @SerializedName("ky_pp") - KY_PP("ky_pp"), - @SerializedName("kz_iin") KZ_IIN("kz_iin"), @SerializedName("li_peid") LI_PEID("li_peid"), - @SerializedName("lk_nic") - LK_NIC("lk_nic"), - @SerializedName("lt_ak") LT_AK("lt_ak"), @@ -9326,15 +9218,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_pk") LV_PK("lv_pk"), - @SerializedName("mo_bir") - MO_BIR("mo_bir"), - - @SerializedName("mt_nic") - MT_NIC("mt_nic"), - - @SerializedName("mv_tin") - MV_TIN("mv_tin"), - @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -9356,15 +9239,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), - @SerializedName("pa_ruc") - PA_RUC("pa_ruc"), - @SerializedName("pe_dni") PE_DNI("pe_dni"), - @SerializedName("ph_tin") - PH_TIN("ph_tin"), - @SerializedName("pk_cnic") PK_CNIC("pk_cnic"), @@ -9377,9 +9254,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_nif") PT_NIF("pt_nif"), - @SerializedName("py_ruc") - PY_RUC("py_ruc"), - @SerializedName("ro_cnp") RO_CNP("ro_cnp"), @@ -9395,15 +9269,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sg_nric") SG_NRIC("sg_nric"), - @SerializedName("si_pin") - SI_PIN("si_pin"), - @SerializedName("sk_dic") SK_DIC("sk_dic"), - @SerializedName("sv_nit") - SV_NIT("sv_nit"), - @SerializedName("th_lc") TH_LC("th_lc"), @@ -9428,9 +9296,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("uy_dni") UY_DNI("uy_dni"), - @SerializedName("vg_pp") - VG_PP("vg_pp"), - @SerializedName("za_id") ZA_ID("za_id"); diff --git a/src/main/java/com/stripe/param/v2/core/AccountUpdateParams.java b/src/main/java/com/stripe/param/v2/core/AccountUpdateParams.java index 0496cd0ad75..97443bedc14 100644 --- a/src/main/java/com/stripe/param/v2/core/AccountUpdateParams.java +++ b/src/main/java/com/stripe/param/v2/core/AccountUpdateParams.java @@ -26995,18 +26995,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_vat") BG_VAT("bg_vat"), - @SerializedName("bm_crn") - BM_CRN("bm_crn"), - - @SerializedName("bo_tin") - BO_TIN("bo_tin"), - @SerializedName("br_cnpj") BR_CNPJ("br_cnpj"), - @SerializedName("bt_tpn") - BT_TPN("bt_tpn"), - @SerializedName("ca_cn") CA_CN("ca_cn"), @@ -27028,9 +27019,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ch_uid") CH_UID("ch_uid"), - @SerializedName("co_nit") - CO_NIT("co_nit"), - @SerializedName("cr_cpj") CR_CPJ("cr_cpj"), @@ -27070,18 +27058,12 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("do_rcn") DO_RCN("do_rcn"), - @SerializedName("ec_ruc") - EC_RUC("ec_ruc"), - @SerializedName("ee_rk") EE_RK("ee_rk"), @SerializedName("ee_vat") EE_VAT("ee_vat"), - @SerializedName("eg_tin") - EG_TIN("eg_tin"), - @SerializedName("es_cif") ES_CIF("es_cif"), @@ -27109,9 +27091,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_vat") GB_VAT("gb_vat"), - @SerializedName("gh_tin") - GH_TIN("gh_tin"), - @SerializedName("gi_crn") GI_CRN("gi_crn"), @@ -27127,18 +27106,12 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gt_nit") GT_NIT("gt_nit"), - @SerializedName("gy_tin") - GY_TIN("gy_tin"), - @SerializedName("hk_br") HK_BR("hk_br"), @SerializedName("hk_cr") HK_CR("hk_cr"), - @SerializedName("hn_rtn") - HN_RTN("hn_rtn"), - @SerializedName("hr_mbs") HR_MBS("hr_mbs"), @@ -27172,30 +27145,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_vat") IT_VAT("it_vat"), - @SerializedName("jm_trn") - JM_TRN("jm_trn"), - - @SerializedName("jo_crn") - JO_CRN("jo_crn"), - @SerializedName("jp_cn") JP_CN("jp_cn"), - @SerializedName("ke_pin") - KE_PIN("ke_pin"), - - @SerializedName("ky_crn") - KY_CRN("ky_crn"), - @SerializedName("kz_bin") KZ_BIN("kz_bin"), @SerializedName("li_uid") LI_UID("li_uid"), - @SerializedName("lk_tin") - LK_TIN("lk_tin"), - @SerializedName("lt_ccrn") LT_CCRN("lt_ccrn"), @@ -27217,9 +27175,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_vat") LV_VAT("lv_vat"), - @SerializedName("mo_tin") - MO_TIN("mo_tin"), - @SerializedName("mt_crn") MT_CRN("mt_crn"), @@ -27229,9 +27184,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("mt_vat") MT_VAT("mt_vat"), - @SerializedName("mv_tin") - MV_TIN("mv_tin"), - @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -27250,9 +27202,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("mz_nuit") MZ_NUIT("mz_nuit"), - @SerializedName("ng_tin") - NG_TIN("ng_tin"), - @SerializedName("nl_kvk") NL_KVK("nl_kvk"), @@ -27271,15 +27220,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), - @SerializedName("pa_ruc") - PA_RUC("pa_ruc"), - @SerializedName("pe_ruc") PE_RUC("pe_ruc"), - @SerializedName("ph_tin") - PH_TIN("ph_tin"), - @SerializedName("pk_ntn") PK_NTN("pk_ntn"), @@ -27295,9 +27238,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_vat") PT_VAT("pt_vat"), - @SerializedName("py_ruc") - PY_RUC("py_ruc"), - @SerializedName("ro_cui") RO_CUI("ro_cui"), @@ -27340,12 +27280,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sk_vat") SK_VAT("sk_vat"), - @SerializedName("sl_tin") - SL_TIN("sl_tin"), - - @SerializedName("sv_nit") - SV_NIT("sv_nit"), - @SerializedName("th_crn") TH_CRN("th_crn"), @@ -27356,16 +27290,7 @@ public enum Type implements ApiRequestParams.EnumParam { TH_TIN("th_tin"), @SerializedName("us_ein") - US_EIN("us_ein"), - - @SerializedName("uy_ruc") - UY_RUC("uy_ruc"), - - @SerializedName("vg_cn") - VG_CN("vg_cn"), - - @SerializedName("za_tin") - ZA_TIN("za_tin"); + US_EIN("us_ein"); @Getter(onMethod_ = {@Override}) private final String value; @@ -30823,21 +30748,12 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_ucn") BG_UCN("bg_ucn"), - @SerializedName("bm_pp") - BM_PP("bm_pp"), - @SerializedName("bn_nric") BN_NRIC("bn_nric"), - @SerializedName("bo_ci") - BO_CI("bo_ci"), - @SerializedName("br_cpf") BR_CPF("br_cpf"), - @SerializedName("bt_cid") - BT_CID("bt_cid"), - @SerializedName("ca_sin") CA_SIN("ca_sin"), @@ -30889,9 +30805,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ee_ik") EE_IK("ee_ik"), - @SerializedName("eg_tin") - EG_TIN("eg_tin"), - @SerializedName("es_nif") ES_NIF("es_nif"), @@ -30904,24 +30817,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_nino") GB_NINO("gb_nino"), - @SerializedName("gh_pin") - GH_PIN("gh_pin"), - @SerializedName("gr_afm") GR_AFM("gr_afm"), @SerializedName("gt_nit") GT_NIT("gt_nit"), - @SerializedName("gy_tin") - GY_TIN("gy_tin"), - @SerializedName("hk_id") HK_ID("hk_id"), - @SerializedName("hn_rtn") - HN_RTN("hn_rtn"), - @SerializedName("hr_oib") HR_OIB("hr_oib"), @@ -30940,30 +30844,18 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_cf") IT_CF("it_cf"), - @SerializedName("jm_trn") - JM_TRN("jm_trn"), - - @SerializedName("jo_pin") - JO_PIN("jo_pin"), - @SerializedName("jp_inc") JP_INC("jp_inc"), @SerializedName("ke_pin") KE_PIN("ke_pin"), - @SerializedName("ky_pp") - KY_PP("ky_pp"), - @SerializedName("kz_iin") KZ_IIN("kz_iin"), @SerializedName("li_peid") LI_PEID("li_peid"), - @SerializedName("lk_nic") - LK_NIC("lk_nic"), - @SerializedName("lt_ak") LT_AK("lt_ak"), @@ -30973,15 +30865,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_pk") LV_PK("lv_pk"), - @SerializedName("mo_bir") - MO_BIR("mo_bir"), - - @SerializedName("mt_nic") - MT_NIC("mt_nic"), - - @SerializedName("mv_tin") - MV_TIN("mv_tin"), - @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -31003,15 +30886,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), - @SerializedName("pa_ruc") - PA_RUC("pa_ruc"), - @SerializedName("pe_dni") PE_DNI("pe_dni"), - @SerializedName("ph_tin") - PH_TIN("ph_tin"), - @SerializedName("pk_cnic") PK_CNIC("pk_cnic"), @@ -31024,9 +30901,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_nif") PT_NIF("pt_nif"), - @SerializedName("py_ruc") - PY_RUC("py_ruc"), - @SerializedName("ro_cnp") RO_CNP("ro_cnp"), @@ -31042,15 +30916,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sg_nric") SG_NRIC("sg_nric"), - @SerializedName("si_pin") - SI_PIN("si_pin"), - @SerializedName("sk_dic") SK_DIC("sk_dic"), - @SerializedName("sv_nit") - SV_NIT("sv_nit"), - @SerializedName("th_lc") TH_LC("th_lc"), @@ -31075,9 +30943,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("uy_dni") UY_DNI("uy_dni"), - @SerializedName("vg_pp") - VG_PP("vg_pp"), - @SerializedName("za_id") ZA_ID("za_id"); diff --git a/src/main/java/com/stripe/param/v2/core/accounts/PersonCreateParams.java b/src/main/java/com/stripe/param/v2/core/accounts/PersonCreateParams.java index 2c10a824029..23964e137e1 100644 --- a/src/main/java/com/stripe/param/v2/core/accounts/PersonCreateParams.java +++ b/src/main/java/com/stripe/param/v2/core/accounts/PersonCreateParams.java @@ -2335,21 +2335,12 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_ucn") BG_UCN("bg_ucn"), - @SerializedName("bm_pp") - BM_PP("bm_pp"), - @SerializedName("bn_nric") BN_NRIC("bn_nric"), - @SerializedName("bo_ci") - BO_CI("bo_ci"), - @SerializedName("br_cpf") BR_CPF("br_cpf"), - @SerializedName("bt_cid") - BT_CID("bt_cid"), - @SerializedName("ca_sin") CA_SIN("ca_sin"), @@ -2401,9 +2392,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ee_ik") EE_IK("ee_ik"), - @SerializedName("eg_tin") - EG_TIN("eg_tin"), - @SerializedName("es_nif") ES_NIF("es_nif"), @@ -2416,24 +2404,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_nino") GB_NINO("gb_nino"), - @SerializedName("gh_pin") - GH_PIN("gh_pin"), - @SerializedName("gr_afm") GR_AFM("gr_afm"), @SerializedName("gt_nit") GT_NIT("gt_nit"), - @SerializedName("gy_tin") - GY_TIN("gy_tin"), - @SerializedName("hk_id") HK_ID("hk_id"), - @SerializedName("hn_rtn") - HN_RTN("hn_rtn"), - @SerializedName("hr_oib") HR_OIB("hr_oib"), @@ -2452,30 +2431,18 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_cf") IT_CF("it_cf"), - @SerializedName("jm_trn") - JM_TRN("jm_trn"), - - @SerializedName("jo_pin") - JO_PIN("jo_pin"), - @SerializedName("jp_inc") JP_INC("jp_inc"), @SerializedName("ke_pin") KE_PIN("ke_pin"), - @SerializedName("ky_pp") - KY_PP("ky_pp"), - @SerializedName("kz_iin") KZ_IIN("kz_iin"), @SerializedName("li_peid") LI_PEID("li_peid"), - @SerializedName("lk_nic") - LK_NIC("lk_nic"), - @SerializedName("lt_ak") LT_AK("lt_ak"), @@ -2485,15 +2452,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_pk") LV_PK("lv_pk"), - @SerializedName("mo_bir") - MO_BIR("mo_bir"), - - @SerializedName("mt_nic") - MT_NIC("mt_nic"), - - @SerializedName("mv_tin") - MV_TIN("mv_tin"), - @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -2515,15 +2473,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), - @SerializedName("pa_ruc") - PA_RUC("pa_ruc"), - @SerializedName("pe_dni") PE_DNI("pe_dni"), - @SerializedName("ph_tin") - PH_TIN("ph_tin"), - @SerializedName("pk_cnic") PK_CNIC("pk_cnic"), @@ -2536,9 +2488,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_nif") PT_NIF("pt_nif"), - @SerializedName("py_ruc") - PY_RUC("py_ruc"), - @SerializedName("ro_cnp") RO_CNP("ro_cnp"), @@ -2554,15 +2503,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sg_nric") SG_NRIC("sg_nric"), - @SerializedName("si_pin") - SI_PIN("si_pin"), - @SerializedName("sk_dic") SK_DIC("sk_dic"), - @SerializedName("sv_nit") - SV_NIT("sv_nit"), - @SerializedName("th_lc") TH_LC("th_lc"), @@ -2587,9 +2530,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("uy_dni") UY_DNI("uy_dni"), - @SerializedName("vg_pp") - VG_PP("vg_pp"), - @SerializedName("za_id") ZA_ID("za_id"); diff --git a/src/main/java/com/stripe/param/v2/core/accounts/PersonTokenCreateParams.java b/src/main/java/com/stripe/param/v2/core/accounts/PersonTokenCreateParams.java index f63fa28f248..47d2c7f0f15 100644 --- a/src/main/java/com/stripe/param/v2/core/accounts/PersonTokenCreateParams.java +++ b/src/main/java/com/stripe/param/v2/core/accounts/PersonTokenCreateParams.java @@ -2305,21 +2305,12 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_ucn") BG_UCN("bg_ucn"), - @SerializedName("bm_pp") - BM_PP("bm_pp"), - @SerializedName("bn_nric") BN_NRIC("bn_nric"), - @SerializedName("bo_ci") - BO_CI("bo_ci"), - @SerializedName("br_cpf") BR_CPF("br_cpf"), - @SerializedName("bt_cid") - BT_CID("bt_cid"), - @SerializedName("ca_sin") CA_SIN("ca_sin"), @@ -2371,9 +2362,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ee_ik") EE_IK("ee_ik"), - @SerializedName("eg_tin") - EG_TIN("eg_tin"), - @SerializedName("es_nif") ES_NIF("es_nif"), @@ -2386,24 +2374,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_nino") GB_NINO("gb_nino"), - @SerializedName("gh_pin") - GH_PIN("gh_pin"), - @SerializedName("gr_afm") GR_AFM("gr_afm"), @SerializedName("gt_nit") GT_NIT("gt_nit"), - @SerializedName("gy_tin") - GY_TIN("gy_tin"), - @SerializedName("hk_id") HK_ID("hk_id"), - @SerializedName("hn_rtn") - HN_RTN("hn_rtn"), - @SerializedName("hr_oib") HR_OIB("hr_oib"), @@ -2422,30 +2401,18 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_cf") IT_CF("it_cf"), - @SerializedName("jm_trn") - JM_TRN("jm_trn"), - - @SerializedName("jo_pin") - JO_PIN("jo_pin"), - @SerializedName("jp_inc") JP_INC("jp_inc"), @SerializedName("ke_pin") KE_PIN("ke_pin"), - @SerializedName("ky_pp") - KY_PP("ky_pp"), - @SerializedName("kz_iin") KZ_IIN("kz_iin"), @SerializedName("li_peid") LI_PEID("li_peid"), - @SerializedName("lk_nic") - LK_NIC("lk_nic"), - @SerializedName("lt_ak") LT_AK("lt_ak"), @@ -2455,15 +2422,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_pk") LV_PK("lv_pk"), - @SerializedName("mo_bir") - MO_BIR("mo_bir"), - - @SerializedName("mt_nic") - MT_NIC("mt_nic"), - - @SerializedName("mv_tin") - MV_TIN("mv_tin"), - @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -2485,15 +2443,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), - @SerializedName("pa_ruc") - PA_RUC("pa_ruc"), - @SerializedName("pe_dni") PE_DNI("pe_dni"), - @SerializedName("ph_tin") - PH_TIN("ph_tin"), - @SerializedName("pk_cnic") PK_CNIC("pk_cnic"), @@ -2506,9 +2458,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_nif") PT_NIF("pt_nif"), - @SerializedName("py_ruc") - PY_RUC("py_ruc"), - @SerializedName("ro_cnp") RO_CNP("ro_cnp"), @@ -2524,15 +2473,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sg_nric") SG_NRIC("sg_nric"), - @SerializedName("si_pin") - SI_PIN("si_pin"), - @SerializedName("sk_dic") SK_DIC("sk_dic"), - @SerializedName("sv_nit") - SV_NIT("sv_nit"), - @SerializedName("th_lc") TH_LC("th_lc"), @@ -2557,9 +2500,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("uy_dni") UY_DNI("uy_dni"), - @SerializedName("vg_pp") - VG_PP("vg_pp"), - @SerializedName("za_id") ZA_ID("za_id"); diff --git a/src/main/java/com/stripe/param/v2/core/accounts/PersonUpdateParams.java b/src/main/java/com/stripe/param/v2/core/accounts/PersonUpdateParams.java index f0a7b7f98a6..001c826555a 100644 --- a/src/main/java/com/stripe/param/v2/core/accounts/PersonUpdateParams.java +++ b/src/main/java/com/stripe/param/v2/core/accounts/PersonUpdateParams.java @@ -2553,21 +2553,12 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_ucn") BG_UCN("bg_ucn"), - @SerializedName("bm_pp") - BM_PP("bm_pp"), - @SerializedName("bn_nric") BN_NRIC("bn_nric"), - @SerializedName("bo_ci") - BO_CI("bo_ci"), - @SerializedName("br_cpf") BR_CPF("br_cpf"), - @SerializedName("bt_cid") - BT_CID("bt_cid"), - @SerializedName("ca_sin") CA_SIN("ca_sin"), @@ -2619,9 +2610,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ee_ik") EE_IK("ee_ik"), - @SerializedName("eg_tin") - EG_TIN("eg_tin"), - @SerializedName("es_nif") ES_NIF("es_nif"), @@ -2634,24 +2622,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_nino") GB_NINO("gb_nino"), - @SerializedName("gh_pin") - GH_PIN("gh_pin"), - @SerializedName("gr_afm") GR_AFM("gr_afm"), @SerializedName("gt_nit") GT_NIT("gt_nit"), - @SerializedName("gy_tin") - GY_TIN("gy_tin"), - @SerializedName("hk_id") HK_ID("hk_id"), - @SerializedName("hn_rtn") - HN_RTN("hn_rtn"), - @SerializedName("hr_oib") HR_OIB("hr_oib"), @@ -2670,30 +2649,18 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_cf") IT_CF("it_cf"), - @SerializedName("jm_trn") - JM_TRN("jm_trn"), - - @SerializedName("jo_pin") - JO_PIN("jo_pin"), - @SerializedName("jp_inc") JP_INC("jp_inc"), @SerializedName("ke_pin") KE_PIN("ke_pin"), - @SerializedName("ky_pp") - KY_PP("ky_pp"), - @SerializedName("kz_iin") KZ_IIN("kz_iin"), @SerializedName("li_peid") LI_PEID("li_peid"), - @SerializedName("lk_nic") - LK_NIC("lk_nic"), - @SerializedName("lt_ak") LT_AK("lt_ak"), @@ -2703,15 +2670,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_pk") LV_PK("lv_pk"), - @SerializedName("mo_bir") - MO_BIR("mo_bir"), - - @SerializedName("mt_nic") - MT_NIC("mt_nic"), - - @SerializedName("mv_tin") - MV_TIN("mv_tin"), - @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -2733,15 +2691,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), - @SerializedName("pa_ruc") - PA_RUC("pa_ruc"), - @SerializedName("pe_dni") PE_DNI("pe_dni"), - @SerializedName("ph_tin") - PH_TIN("ph_tin"), - @SerializedName("pk_cnic") PK_CNIC("pk_cnic"), @@ -2754,9 +2706,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_nif") PT_NIF("pt_nif"), - @SerializedName("py_ruc") - PY_RUC("py_ruc"), - @SerializedName("ro_cnp") RO_CNP("ro_cnp"), @@ -2772,15 +2721,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sg_nric") SG_NRIC("sg_nric"), - @SerializedName("si_pin") - SI_PIN("si_pin"), - @SerializedName("sk_dic") SK_DIC("sk_dic"), - @SerializedName("sv_nit") - SV_NIT("sv_nit"), - @SerializedName("th_lc") TH_LC("th_lc"), @@ -2805,9 +2748,6 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("uy_dni") UY_DNI("uy_dni"), - @SerializedName("vg_pp") - VG_PP("vg_pp"), - @SerializedName("za_id") ZA_ID("za_id"); diff --git a/src/main/java/com/stripe/service/v2/moneymanagement/PayoutMethodService.java b/src/main/java/com/stripe/service/v2/moneymanagement/PayoutMethodService.java index e9ae637ca52..2d529c24ffb 100644 --- a/src/main/java/com/stripe/service/v2/moneymanagement/PayoutMethodService.java +++ b/src/main/java/com/stripe/service/v2/moneymanagement/PayoutMethodService.java @@ -2,6 +2,7 @@ package com.stripe.service.v2.moneymanagement; import com.google.gson.reflect.TypeToken; +import com.stripe.exception.CannotProceedException; import com.stripe.exception.ControlledByAlternateResourceException; import com.stripe.exception.ControlledByDashboardException; import com.stripe.exception.InvalidPayoutMethodException; @@ -65,8 +66,8 @@ public PayoutMethod retrieve(String id, RequestOptions options) * appear in the payout method list. */ public PayoutMethod archive(String id) - throws StripeException, ControlledByDashboardException, InvalidPayoutMethodException, - ControlledByAlternateResourceException { + throws StripeException, ControlledByDashboardException, CannotProceedException, + InvalidPayoutMethodException, ControlledByAlternateResourceException { return archive(id, (RequestOptions) null); } /** @@ -74,8 +75,8 @@ public PayoutMethod archive(String id) * appear in the payout method list. */ public PayoutMethod archive(String id, RequestOptions options) - throws StripeException, ControlledByDashboardException, InvalidPayoutMethodException, - ControlledByAlternateResourceException { + throws StripeException, ControlledByDashboardException, CannotProceedException, + InvalidPayoutMethodException, ControlledByAlternateResourceException { String path = String.format( "/v2/money_management/payout_methods/%s/archive", ApiResource.urlEncodeId(id)); diff --git a/src/test/java/com/stripe/functional/GeneratedExamples.java b/src/test/java/com/stripe/functional/GeneratedExamples.java index b0f72d93a01..a88fb3f366e 100644 --- a/src/test/java/com/stripe/functional/GeneratedExamples.java +++ b/src/test/java/com/stripe/functional/GeneratedExamples.java @@ -30964,6 +30964,32 @@ public void testBlockedByStripeErrorServices() throws StripeException { null); } + @Test + public void testCannotProceedErrorServices() throws StripeException { + stubRequestReturnError( + BaseAddress.API, + ApiResource.RequestMethod.POST, + "/v2/money_management/payout_methods/id_123/archive", + null, + null, + "{\"error\":{\"type\":\"cannot_proceed\",\"code\":\"default_payout_method_cannot_be_archived\"}}", + 400); + StripeClient client = new StripeClient(networkSpy); + + try { + client.v2().moneyManagement().payoutMethods().archive("id_123"); + } catch (CannotProceedException e) { + + } + ; + verifyRequest( + BaseAddress.API, + ApiResource.RequestMethod.POST, + "/v2/money_management/payout_methods/id_123/archive", + null, + null); + } + @Test public void testControlledByAlternateResourceErrorServices() throws StripeException { stubRequestReturnError(