/** * @rajeev02/payments — Cards & Subscriptions * Card tokenization (RBI compliant), saved cards, recurring billing */ export interface CardInfo { /** Tokenized card reference (never store raw card numbers) */ tokenRef: string; /** Last 4 digits for display */ last4: string; /** Card network */ network: "visa" | "mastercard" | "rupay" | "amex" | "dinersclub"; /** Card type */ type: "credit" | "debit" | "prepaid"; /** Issuing bank name */ issuerBank?: string; /** Expiry month */ expiryMonth: number; /** Expiry year */ expiryYear: number; /** Cardholder name */ holderName?: string; /** Whether card supports recurring/mandate */ supportsRecurring: boolean; } export interface SubscriptionPlan { id: string; name: string; description?: string; amount: number; currency: string; interval: "daily" | "weekly" | "monthly" | "quarterly" | "yearly"; intervalCount: number; trialDays?: number; features?: string[]; } export interface Subscription { id: string; planId: string; customerId: string; status: "active" | "paused" | "cancelled" | "past_due" | "trialing" | "expired"; currentPeriodStart: string; currentPeriodEnd: string; cancelledAt?: string; paymentMethod: "card" | "upi_mandate" | "emandate"; tokenRef?: string; nextBillingDate: string; amount: number; } /** * Detect card network from number prefix (first 6 digits) */ export declare function detectCardNetwork(cardNumber: string): CardInfo["network"] | null; /** * Format card number with spaces: 4111111111111111 → 4111 1111 1111 1111 */ export declare function formatCardNumber(cardNumber: string): string; /** * Validate card number using Luhn algorithm */ export declare function validateCardNumber(cardNumber: string): boolean; /** * Calculate subscription renewal dates */ export declare function getNextBillingDate(plan: SubscriptionPlan, currentDate?: Date): Date; //# sourceMappingURL=index.d.ts.map