import { BaseAPI } from './common/base-api'; import type Configuration from './common/configuration'; import type PaymentRequest from './models/payment-request'; import type PaymentResponse from './models/payment-response'; import RefundRequest from './models/refund-request'; import RefundResponse from './models/refund-response'; import type RetrievePaymentResponse from './models/retrieve-payment-response'; import { RetrieveRefundResponse } from './models/retrieve-refund-response'; /** * LinkPay API */ export default class LinkPayAPI extends BaseAPI { constructor(configuration: Configuration); /** * This API is used to create a LinkPay order and get a Payment Link. This API supports idempotentency, if the * merchant does not receive the response for this API, it can re-call this API with the same * merchantOrderID, merchantOrderTime and transAmount object. * * @param body LinkPay Request Message * @returns */ payment(body: PaymentRequest): Promise; /** * This API is used to retrieve the transaction record from the LinkPay based on the merchantOrderID. This * interface only supports to query the payment status of the LinkPay order. * * @param merchantOrderID Merchant Order ID * @returns */ retrievePayment(merchantOrderID: string): Promise; /** * This API is used to refund the transaction fund from the LinkPay based on the merchantOrderID. This * interface only supports to refund the paid LinkPay order. And this interface supports partial refund as well. * * @param merchantOrderID Merchant Order ID * @param body Request Message * @returns */ refund(merchantOrderID: string, body: RefundRequest): Promise; /** * This API is used to retrieve the refund transaction record from the LinkPay based on the merchantTransID * of LinkPay refund transaction. This interface only supports to query the refund status of * the LinkPay refund transaction. * * @param merchantTransID Merchant Transaction ID * @returns */ retrieveRefund(merchantTransID: string): Promise; }