export type RecurringPaymentJobDraft = { originPayment: { id: string; typeId: string; }; paymentMethod: { id: string; typeId: string; }; }; export type RecurringPaymentJob = { id: string; version: number; createdAt: string; lastModifiedAt: string; originPayment?: { id: string; typeId: string; }; paymentMethod?: { id: string; typeId: string; }; status: { state: string; }; }; export interface RecurringPaymentJobService { /** * Ensures a recurring payment job is created if the payment's cart is configured for recurring payments. * Returns null if the cart is not configured for recurring payments or if an error occurs. */ createRecurringPaymentJobIfApplicable(draft: RecurringPaymentJobDraft): Promise; }