import { NativeModules } from 'react-native'; import type { PaymentConsent, PaymentSession } from './types'; import type { PaymentResult } from './types/PaymentResult'; import type { Card } from './types/Card'; type NativeAirwallexSdkType = { initialize( environment: 'staging' | 'demo' | 'production', enableLogging: boolean, saveLogToLocal: boolean ): void; presentEntirePaymentFlow(session: PaymentSession): Promise; presentCardPaymentFlow(session: PaymentSession): Promise; startGooglePay(session: PaymentSession): Promise; startApplePay(session: PaymentSession): Promise; payWithCardDetails( session: PaymentSession, card: Card, saveCard: boolean ): Promise; payWithConsent( session: PaymentSession, consent: PaymentConsent ): Promise; }; const { AirwallexSdk } = NativeModules; export default AirwallexSdk as NativeAirwallexSdkType;