import type Stripe from 'stripe'; import { type BillableContract } from './contracts.js'; export declare class Payment { #private; constructor(paymentIntent: Stripe.PaymentIntent); /** * Get the original Stripe PaymentIntent */ get paymentIntent(): Stripe.PaymentIntent; /** * Get the total amount that will be paid. */ amount(): string; /** * Get the raw total amount that will be paid. */ rawAmount(): number; /** * The Stripe PaymentIntent client secret. */ clientSecret(): string | null; /** * Capture a payment that is being held for the customer. */ capture(params?: Stripe.PaymentIntentCaptureParams): Promise; /** * Determine if the payment needs a valid payment method. */ requiresPaymentMethod(): boolean; /** * Determine if the payment needs an extra action like 3D Secure. */ requiresAction(): boolean; /** * Determine if the payment needs to be confirmed. */ requiresConfirmation(): boolean; /** * Determine if the payment needs to be captured. */ requireCaptures(): boolean; /** * Cancel the payment. */ cancel(params?: Stripe.PaymentIntentCancelParams): Promise; /** * Determine if the payment was canceled. */ isCanceled(): boolean; /** * Determine if the payment was successful. */ isSucceeded(): boolean; /** * Determine if the payment is processing. */ isProcessing(): boolean; /** * Format the given amount into a displayable currency. */ formatAmount(amount: number): string; /** * Validate if the payment intent was successful and throw an exception if not. */ validate(): boolean; /** * Retrieve the related customer for the payment intent if one exists. */ customer(): Promise; customerOrFail(): Promise; /** * Confirms the payment intent. */ confirm(params?: Stripe.PaymentIntentConfirmParams): Promise; /** * The Stripe PaymentIntent instance. */ asStripePaymentIntent(expand?: string[]): Promise; }