Builder

class Builder

The PaymentIntentParameters.Builder class provides a convenient way to create a new PaymentIntentParameters instance without having to deal with parameters that aren't relevant to your integration.

Constructors

Link copied to clipboard
constructor(amount: Long, currency: String, captureMethod: CaptureMethod, allowedPaymentMethodTypes: List<PaymentMethodType> = listOf(PaymentMethodType.CARD_PRESENT))

Create a builder for creating a PaymentIntent.

constructor(allowedPaymentMethodTypes: List<PaymentMethodType> = listOf(PaymentMethodType.CARD_PRESENT))

Create a simple builder for creating a PaymentIntent.

Functions

Link copied to clipboard

Create a final instance of PaymentIntentParameters with the parameters that you've set.

Link copied to clipboard

Set the amount of the payment, provided in the currency's smallest unit.

Link copied to clipboard

Set the amount of the application fee (if any) that will be applied to the payment and transferred to the application owner’s Stripe account. To use an application fee, the request must be made on behalf of another account, using the stripeAccount property or an OAuth key.

Link copied to clipboard

Set the capture method, which controls when the funds will be captured from the customer's account. Defaults to "manual" if not set.

Link copied to clipboard

Set the three-letter ISO currency code, in lowercase. Must be a supported currency.

Link copied to clipboard

Set the ID of the Customer this PaymentIntent is for, if one exists.

Link copied to clipboard

Set the description - an arbitrary string attached to the object. If you send a receipt email for this payment, the email will include the description.

Link copied to clipboard

Set the map of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.

Link copied to clipboard

Set the Stripe account ID for which these funds are intended.

Link copied to clipboard

Set a payment-method-specific configuration for this PaymentIntent.

Link copied to clipboard

Set the email address that the receipt for the resulting payment will be sent to.

Link copied to clipboard

Set a string (if any) that indicates the type of future usage (possible values: off_session, on_session)

Link copied to clipboard

Set a string to be displayed on your customer's credit card statement. This may be up to 22 characters. The statement descriptor must contain at least one letter, may not include <>"' characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped. While most banks and card issuers display this information consistently, some may display it incorrectly or not at all.

Link copied to clipboard

A string to specify details about the transaction so your customer can understand it clearly on their statement. The suffix is concatenated with the statementDescriptor, the * symbol, and a space to form the complete statement descriptor that your customer sees. Maximum 22 characters for the final concatenated descriptor.

Link copied to clipboard

Set the account (if any) the payment will be attributed to for tax reporting, and where funds from the payment will be transferred to upon payment success.

Link copied to clipboard

Set a string that identifies the resulting payment as part of a group.