Type Alias CustomerSheetInitParams

CustomerSheetInitParams: {
    style?: "alwaysLight" | "alwaysDark" | "automatic";
    appearance?: AppearanceParams;
    setupIntentClientSecret?: string;
    customerId: string;
    customerEphemeralKeySecret: string;
    merchantDisplayName?: string;
    headerTextForSelectionScreen?: string;
    defaultBillingDetails?: BillingDetails;
    billingDetailsCollectionConfiguration?: BillingDetailsCollectionConfiguration;
    returnURL?: string;
    removeSavedPaymentMethodMessage?: string;
    applePayEnabled?: boolean;
    googlePayEnabled?: boolean;
    preferredNetworks?: CardBrand[];
    customerAdapter?: CustomerAdapter;
    allowsRemovalOfLastSavedPaymentMethod?: boolean;
    cardBrandAcceptance?: CardBrandAcceptance;
}

Type declaration

  • Optionalstyle?: "alwaysLight" | "alwaysDark" | "automatic"

    The color styling to use for PaymentSheet UI. Defaults to 'automatic'. iOS only.

  • Optionalappearance?: AppearanceParams

    Configuration for the look and feel of the UI.

  • OptionalsetupIntentClientSecret?: string

    Optional but recommended for cards, required for other payment methods. The SetupIntent client secret that will be used to confirm a new payment method. If this is missing, you will only be able to add cards without authentication steps.

  • customerId: string

    The identifier of the Stripe Customer object. See https://stripe.com/docs/api/customers/object#customer_object-id

  • customerEphemeralKeySecret: string

    A short-lived token that allows the SDK to access a Customer's payment methods.

  • OptionalmerchantDisplayName?: string

    Your customer-facing business name. The default value is the name of your app.

  • OptionalheaderTextForSelectionScreen?: string

    Optional configuration for setting the header text of the Payment Method selection screen

  • OptionaldefaultBillingDetails?: BillingDetails

    CustomerSheet pre-populates fields with the values provided. If billingDetailsCollectionConfiguration.attachDefaultsToPaymentMethod is true, these values will be attached to the payment method even if they are not collected by the CustomerSheet UI.

  • OptionalbillingDetailsCollectionConfiguration?: BillingDetailsCollectionConfiguration

    Describes how billing details should be collected. All values default to AUTOMATIC. If NEVER is used for a required field for the Payment Method, you must provide an appropriate value as part of defaultBillingDetails.

  • OptionalreturnURL?: string

    A URL that redirects back to your app that CustomerSheet can use to auto-dismiss web views used for additional authentication, e.g. 3DS2

  • OptionalremoveSavedPaymentMethodMessage?: string

    Optional configuration to display a custom message when a saved payment method is removed. iOS only.

  • OptionalapplePayEnabled?: boolean

    Whether to show Apple Pay as an option. Defaults to false.

  • OptionalgooglePayEnabled?: boolean

    Whether to show Google Pay as an option. Defaults to false.

  • OptionalpreferredNetworks?: CardBrand[]

    The list of preferred networks that should be used to process payments made with a co-branded card. This value will only be used if your user hasn't selected a network themselves.

  • OptionalcustomerAdapter?: CustomerAdapter

    Optional override. It is generally recommended to rely on the default behavior, but- provide a CustomerAdapter here if you would prefer retrieving and updating your Stripe customer object via your own backend instead. WARNING: When implementing your own CustomerAdapter, ensure your application complies with all applicable laws and regulations, including data privacy and consumer protection.

  • OptionalallowsRemovalOfLastSavedPaymentMethod?: boolean

    This is an experimental feature that may be removed at any time. Defaults to true. If true, the customer can delete all saved payment methods. If false, the customer can't delete if they only have one saved payment method remaining.

  • OptionalcardBrandAcceptance?: CardBrandAcceptance

    By default, CustomerSheet will accept all supported cards by Stripe. You can specify card brands CustomerSheet should block or allow payment for by providing an array of those card brands. Note: This is only a client-side solution. Note: Card brand filtering is not currently supported in Link.

MMNEPVFCICPMFPCPTTAAATR