import { AxiosInstance } from 'axios'; import { CustomerInfo } from './CustomerInfo'; import { SubscriptionInfo } from './SubscriptionInfo'; import { TransactionInfo } from './TransactionInfo'; export declare type SendRequestArgs = { requestId: string; cache?: boolean; }; export declare type FetchTransactionArgs = { merchantConfig: string; transactionId: string; cache?: boolean; }; export declare type FetchSubscriptionArgs = { merchantConfig: string; subscriptionToken: string; cache?: boolean; }; export declare type CancelSubscriptionArgs = { merchantConfig: string; subscriptionToken: string; }; export declare type FetchCustomerArgs = { merchantConfig: string; customerToken: string; cache?: boolean; }; export declare type UpdateCustomerArgs = { merchantConfig: string; customerToken: string; fields: { [key: string]: string | number | boolean; }; }; export interface IEpaymentApiProxy { fetchTransaction(args: FetchTransactionArgs): Promise; fetchSubscription(args: FetchSubscriptionArgs): Promise; cancelSubscription(args: CancelSubscriptionArgs): any; fetchCustomer(args: FetchCustomerArgs): Promise; updateCustomer(args: UpdateCustomerArgs): any; } export declare class CachedEpaymentApiProxy implements IEpaymentApiProxy { private proxyUrl; private http; private requestPool; constructor(proxyUrl: string, http?: AxiosInstance); fetchTransaction({ merchantConfig, transactionId, cache }: FetchTransactionArgs): Promise; fetchSubscription({ merchantConfig, subscriptionToken, cache }: FetchSubscriptionArgs): Promise; cancelSubscription({ merchantConfig, subscriptionToken }: CancelSubscriptionArgs): Promise; fetchCustomer({ merchantConfig, customerToken, cache }: FetchCustomerArgs): Promise; updateCustomer({ merchantConfig, customerToken, fields }: UpdateCustomerArgs): Promise; private sendRequest; private clearRequestPool; private generateRequestId; private getNormalizedFinalStatus; private getNormalizedPaymentMethod; } export declare function createEpaymentApiProxy(proxyUrl: string): IEpaymentApiProxy;