import { FetchStateAndError, FetchedState, ID } from '../../../commonStateTypes/common'; /** * Stripe SetupIntent payload returned by * `POST /customers/{id}/payment-methods/setup-intent`. Used to mount Stripe * Elements for an admin-initiated "Add Payment Method" (card) flow. */ export interface InvoicingSetupIntent { client_secret: string; connected_account_id: string; publishable_key: string; setup_intent_id: string; } export interface InvoicingCustomerPaymentMethodState extends FetchedState { plaidTokenFetchState: FetchStateAndError; saveFetchState: FetchStateAndError; sendLinkFetchState: FetchStateAndError; setupIntentFetchState: FetchStateAndError; /** The customer id of the in-flight payment-method operation. */ customerId?: ID; plaidLinkToken?: string; sentLinkEmail?: string; sentLinkMagicUrl?: string; setupIntent?: InvoicingSetupIntent; }