PayEngineNative class

PayEngineNative provides an interface for interacting with the native PayEngine SDK.

This class utilizes platform channels to bridge communication between Flutter and native platforms, enabling functionalities such as fraud monitoring, browser info retrieval, and Apple Pay / Google Pay support detection.

Constructors

PayEngineNative()

Properties

hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Properties

platformVersion → Future<String>
Retrieves the platform version from the native SDK.
no setter

Static Methods

getBrowserInfo() → Future<String>
Retrieves browser-related information from the native SDK.
getFraudMonitorSession(String merchantId) → Future<String>
Retrieves a fraud monitoring session ID from the native PayEngine SDK.
logout(String merchantId) → Future
Logs out merchantId: revokes the cached session if it's still valid and clears it. The callback stays registered, so the next request fetches a new token.
setConfig(String publicKey, String? scriptURL) → Future
Configures the PayEngine SDK with the provided public key and optional script URL.
setFetchAccessTokenCallback(Future<PEAccessTokenJson> callback()) → void
Sets the callback PayEngine calls to get a merchant session access token.
userCanPay(PayProvider provider, String merchantId) → Future<bool>
Checks if the user can make payments using Apple Pay (iOS) or Google Pay (Android).

Constants

missingAccessTokenCode → const String
Code of the error raised when PayEngine has no merchant session token.
missingAccessTokenMessage → const String
Message of the missingAccessTokenCode error.