trustpayway-sdk
Version:
Official Node.js SDK for interacting with TrustPayWay API (MTN, Orange, etc.)
31 lines (30 loc) • 737 B
TypeScript
interface ProcessPaymentParams {
amount: string;
currency: string;
phone: string;
description: string;
orderId: string;
notifUrl: string;
}
interface CheckStatusParams {
transactionId: string;
}
interface TrustPayWayConfig {
baseUrl: string;
appToken: string;
authToken: string;
network: 'mtn' | 'orange';
}
export declare class TrustPayWay {
private baseUrl;
private appToken;
private authToken;
private network;
private sessionToken;
private http;
constructor(config: TrustPayWayConfig);
getToken(): Promise<string>;
processPayment(params: ProcessPaymentParams): Promise<any>;
checkPaymentStatus(params: CheckStatusParams): Promise<any>;
}
export {};