PaylinkAPI constructor
Initializes the PaylinkAPI with optional test mode, API ID, and secret key.
isTestMode - Indicates whether the API is in test mode.
apiId - Production API ID.
secretKey - Production API secret key.
Implementation
PaylinkAPI({
this.isTestMode = false,
this.apiId,
this.secretKey,
}) {
/// Set API endpoints based on test mode.
apiLink = getApiLink(isTestMode);
super.paymentFrameUrl = getPaymentFrameUrl(isTestMode);
/// Initialize payment token.
paymentToken = null;
}