Package com.stripe.param
Class PaymentMethodCreateParams.Builder
- java.lang.Object
-
- com.stripe.param.PaymentMethodCreateParams.Builder
-
- Enclosing class:
- PaymentMethodCreateParams
public static class PaymentMethodCreateParams.Builder extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PaymentMethodCreateParams.Builder
addAllExpand(java.util.List<java.lang.String> elements)
Add all elements to `expand` list.PaymentMethodCreateParams.Builder
addExpand(java.lang.String element)
Add an element to `expand` list.PaymentMethodCreateParams
build()
Finalize and obtain parameter instance from this builder.PaymentMethodCreateParams.Builder
putAllExtraParam(java.util.Map<java.lang.String,java.lang.Object> map)
Add all map key/value pairs to `extraParams` map.PaymentMethodCreateParams.Builder
putAllMetadata(java.util.Map<java.lang.String,java.lang.String> map)
Add all map key/value pairs to `metadata` map.PaymentMethodCreateParams.Builder
putExtraParam(java.lang.String key, java.lang.Object value)
Add a key/value pair to `extraParams` map.PaymentMethodCreateParams.Builder
putMetadata(java.lang.String key, java.lang.String value)
Add a key/value pair to `metadata` map.PaymentMethodCreateParams.Builder
setAcssDebit(PaymentMethodCreateParams.AcssDebit acssDebit)
If this is anacss_debit
PaymentMethod, this hash contains details about the ACSS Debit payment method.PaymentMethodCreateParams.Builder
setAfterpayClearpay(PaymentMethodCreateParams.AfterpayClearpay afterpayClearpay)
If this is anAfterpayClearpay
PaymentMethod, this hash contains details about the AfterpayClearpay payment method.PaymentMethodCreateParams.Builder
setAlipay(PaymentMethodCreateParams.Alipay alipay)
If this is anAlipay
PaymentMethod, this hash contains details about the Alipay payment method.PaymentMethodCreateParams.Builder
setAuBecsDebit(PaymentMethodCreateParams.AuBecsDebit auBecsDebit)
If this is anau_becs_debit
PaymentMethod, this hash contains details about the bank account.PaymentMethodCreateParams.Builder
setBacsDebit(PaymentMethodCreateParams.BacsDebit bacsDebit)
If this is abacs_debit
PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.PaymentMethodCreateParams.Builder
setBancontact(PaymentMethodCreateParams.Bancontact bancontact)
If this is abancontact
PaymentMethod, this hash contains details about the Bancontact payment method.PaymentMethodCreateParams.Builder
setBillingDetails(PaymentMethodCreateParams.BillingDetails billingDetails)
Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.PaymentMethodCreateParams.Builder
setBoleto(PaymentMethodCreateParams.Boleto boleto)
If this is aboleto
PaymentMethod, this hash contains details about the Boleto payment method.PaymentMethodCreateParams.Builder
setCard(PaymentMethodCreateParams.CardDetails card)
If this is acard
PaymentMethod, this hash contains the user's card details.PaymentMethodCreateParams.Builder
setCard(PaymentMethodCreateParams.Token card)
If this is acard
PaymentMethod, this hash contains the user's card details.PaymentMethodCreateParams.Builder
setCustomer(java.lang.String customer)
TheCustomer
to whom the original PaymentMethod is attached.PaymentMethodCreateParams.Builder
setEps(PaymentMethodCreateParams.Eps eps)
If this is aneps
PaymentMethod, this hash contains details about the EPS payment method.PaymentMethodCreateParams.Builder
setFpx(PaymentMethodCreateParams.Fpx fpx)
If this is anfpx
PaymentMethod, this hash contains details about the FPX payment method.PaymentMethodCreateParams.Builder
setGiropay(PaymentMethodCreateParams.Giropay giropay)
If this is agiropay
PaymentMethod, this hash contains details about the Giropay payment method.PaymentMethodCreateParams.Builder
setGrabpay(PaymentMethodCreateParams.Grabpay grabpay)
If this is agrabpay
PaymentMethod, this hash contains details about the GrabPay payment method.PaymentMethodCreateParams.Builder
setIdeal(PaymentMethodCreateParams.Ideal ideal)
If this is anideal
PaymentMethod, this hash contains details about the iDEAL payment method.PaymentMethodCreateParams.Builder
setInteracPresent(PaymentMethodCreateParams.InteracPresent interacPresent)
If this is aninterac_present
PaymentMethod, this hash contains details about the Interac Present payment method.PaymentMethodCreateParams.Builder
setOxxo(PaymentMethodCreateParams.Oxxo oxxo)
If this is anoxxo
PaymentMethod, this hash contains details about the OXXO payment method.PaymentMethodCreateParams.Builder
setP24(PaymentMethodCreateParams.P24 p24)
If this is ap24
PaymentMethod, this hash contains details about the P24 payment method.PaymentMethodCreateParams.Builder
setPaymentMethod(java.lang.String paymentMethod)
The PaymentMethod to share.PaymentMethodCreateParams.Builder
setSepaDebit(PaymentMethodCreateParams.SepaDebit sepaDebit)
If this is asepa_debit
PaymentMethod, this hash contains details about the SEPA debit bank account.PaymentMethodCreateParams.Builder
setSofort(PaymentMethodCreateParams.Sofort sofort)
If this is asofort
PaymentMethod, this hash contains details about the SOFORT payment method.PaymentMethodCreateParams.Builder
setType(PaymentMethodCreateParams.Type type)
The type of the PaymentMethod.PaymentMethodCreateParams.Builder
setWechatPay(PaymentMethodCreateParams.WechatPay wechatPay)
If this is anwechat_pay
PaymentMethod, this hash contains details about the wechat_pay payment method.
-
-
-
Method Detail
-
build
public PaymentMethodCreateParams build()
Finalize and obtain parameter instance from this builder.
-
setAcssDebit
public PaymentMethodCreateParams.Builder setAcssDebit(PaymentMethodCreateParams.AcssDebit acssDebit)
If this is anacss_debit
PaymentMethod, this hash contains details about the ACSS Debit payment method.
-
setAfterpayClearpay
public PaymentMethodCreateParams.Builder setAfterpayClearpay(PaymentMethodCreateParams.AfterpayClearpay afterpayClearpay)
If this is anAfterpayClearpay
PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
-
setAlipay
public PaymentMethodCreateParams.Builder setAlipay(PaymentMethodCreateParams.Alipay alipay)
If this is anAlipay
PaymentMethod, this hash contains details about the Alipay payment method.
-
setAuBecsDebit
public PaymentMethodCreateParams.Builder setAuBecsDebit(PaymentMethodCreateParams.AuBecsDebit auBecsDebit)
If this is anau_becs_debit
PaymentMethod, this hash contains details about the bank account.
-
setBacsDebit
public PaymentMethodCreateParams.Builder setBacsDebit(PaymentMethodCreateParams.BacsDebit bacsDebit)
If this is abacs_debit
PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
-
setBancontact
public PaymentMethodCreateParams.Builder setBancontact(PaymentMethodCreateParams.Bancontact bancontact)
If this is abancontact
PaymentMethod, this hash contains details about the Bancontact payment method.
-
setBillingDetails
public PaymentMethodCreateParams.Builder setBillingDetails(PaymentMethodCreateParams.BillingDetails billingDetails)
Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
-
setBoleto
public PaymentMethodCreateParams.Builder setBoleto(PaymentMethodCreateParams.Boleto boleto)
If this is aboleto
PaymentMethod, this hash contains details about the Boleto payment method.
-
setCard
public PaymentMethodCreateParams.Builder setCard(PaymentMethodCreateParams.CardDetails card)
If this is acard
PaymentMethod, this hash contains the user's card details. For backwards compatibility, you can alternatively provide a Stripe token (e.g., for Apple Pay, Amex Express Checkout, or legacy Checkout) into the card hash with formatcard: {token: "tok_visa"}
. When providing a card number, you must meet the requirements for PCI compliance. We strongly recommend using Stripe.js instead of interacting with this API directly.
-
setCard
public PaymentMethodCreateParams.Builder setCard(PaymentMethodCreateParams.Token card)
If this is acard
PaymentMethod, this hash contains the user's card details. For backwards compatibility, you can alternatively provide a Stripe token (e.g., for Apple Pay, Amex Express Checkout, or legacy Checkout) into the card hash with formatcard: {token: "tok_visa"}
. When providing a card number, you must meet the requirements for PCI compliance. We strongly recommend using Stripe.js instead of interacting with this API directly.
-
setCustomer
public PaymentMethodCreateParams.Builder setCustomer(java.lang.String customer)
TheCustomer
to whom the original PaymentMethod is attached.
-
setEps
public PaymentMethodCreateParams.Builder setEps(PaymentMethodCreateParams.Eps eps)
If this is aneps
PaymentMethod, this hash contains details about the EPS payment method.
-
addExpand
public PaymentMethodCreateParams.Builder addExpand(java.lang.String element)
Add an element to `expand` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. SeePaymentMethodCreateParams.expand
for the field documentation.
-
addAllExpand
public PaymentMethodCreateParams.Builder addAllExpand(java.util.List<java.lang.String> elements)
Add all elements to `expand` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. SeePaymentMethodCreateParams.expand
for the field documentation.
-
putExtraParam
public PaymentMethodCreateParams.Builder putExtraParam(java.lang.String key, java.lang.Object 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. SeePaymentMethodCreateParams.extraParams
for the field documentation.
-
putAllExtraParam
public PaymentMethodCreateParams.Builder putAllExtraParam(java.util.Map<java.lang.String,java.lang.Object> map)
Add all map key/value pairs to `extraParams` map. A map is initialized for the first `put/putAll` call, and subsequent calls add additional key/value pairs to the original map. SeePaymentMethodCreateParams.extraParams
for the field documentation.
-
setFpx
public PaymentMethodCreateParams.Builder setFpx(PaymentMethodCreateParams.Fpx fpx)
If this is anfpx
PaymentMethod, this hash contains details about the FPX payment method.
-
setGiropay
public PaymentMethodCreateParams.Builder setGiropay(PaymentMethodCreateParams.Giropay giropay)
If this is agiropay
PaymentMethod, this hash contains details about the Giropay payment method.
-
setGrabpay
public PaymentMethodCreateParams.Builder setGrabpay(PaymentMethodCreateParams.Grabpay grabpay)
If this is agrabpay
PaymentMethod, this hash contains details about the GrabPay payment method.
-
setIdeal
public PaymentMethodCreateParams.Builder setIdeal(PaymentMethodCreateParams.Ideal ideal)
If this is anideal
PaymentMethod, this hash contains details about the iDEAL payment method.
-
setInteracPresent
public PaymentMethodCreateParams.Builder setInteracPresent(PaymentMethodCreateParams.InteracPresent interacPresent)
If this is aninterac_present
PaymentMethod, this hash contains details about the Interac Present payment method.
-
putMetadata
public PaymentMethodCreateParams.Builder putMetadata(java.lang.String key, java.lang.String value)
Add a key/value pair to `metadata` map. A map is initialized for the first `put/putAll` call, and subsequent calls add additional key/value pairs to the original map. SeePaymentMethodCreateParams.metadata
for the field documentation.
-
putAllMetadata
public PaymentMethodCreateParams.Builder putAllMetadata(java.util.Map<java.lang.String,java.lang.String> map)
Add all map key/value pairs to `metadata` map. A map is initialized for the first `put/putAll` call, and subsequent calls add additional key/value pairs to the original map. SeePaymentMethodCreateParams.metadata
for the field documentation.
-
setOxxo
public PaymentMethodCreateParams.Builder setOxxo(PaymentMethodCreateParams.Oxxo oxxo)
If this is anoxxo
PaymentMethod, this hash contains details about the OXXO payment method.
-
setP24
public PaymentMethodCreateParams.Builder setP24(PaymentMethodCreateParams.P24 p24)
If this is ap24
PaymentMethod, this hash contains details about the P24 payment method.
-
setPaymentMethod
public PaymentMethodCreateParams.Builder setPaymentMethod(java.lang.String paymentMethod)
The PaymentMethod to share.
-
setSepaDebit
public PaymentMethodCreateParams.Builder setSepaDebit(PaymentMethodCreateParams.SepaDebit sepaDebit)
If this is asepa_debit
PaymentMethod, this hash contains details about the SEPA debit bank account.
-
setSofort
public PaymentMethodCreateParams.Builder setSofort(PaymentMethodCreateParams.Sofort sofort)
If this is asofort
PaymentMethod, this hash contains details about the SOFORT payment method.
-
setType
public PaymentMethodCreateParams.Builder setType(PaymentMethodCreateParams.Type type)
The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
-
setWechatPay
public PaymentMethodCreateParams.Builder setWechatPay(PaymentMethodCreateParams.WechatPay wechatPay)
If this is anwechat_pay
PaymentMethod, this hash contains details about the wechat_pay payment method.
-
-