SwishClient class

Swish Client

Handles communication to the Swish API. Must be created with a SwishAgent which provides the SwishClient with necessary security context.

Constructors

SwishClient({required SwishAgent swishAgent})
Create a SwishClient instance.

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
swishAgent SwishAgent
SwishAgent that handles internal security.
final

Methods

createPaymentRequest({required SwishPaymentData swishPaymentData}) Future<SwishPaymentRequest>
A payment request is a transaction sent from a merchant to the Swish system to initiate an e-commerce or m-commerce payment.
getPaymentRequest({required String location}) Future<SwishPaymentRequest>
Get the payment request from Swish. Will contain information about the status of the payment request in JSON format. (Unstable and under development)
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
openSwish({required SwishPaymentRequest swishPaymentRequest}) Future<void>
Open Swish
toString() String
A string representation of this object.
inherited
waitForPaymentRequest({required String location}) Future<SwishPaymentRequest>
Will wait for the SwishPaymentRequest to change its status from CREATED. Upon a new status waitForPaymentRequest will return the the new SwishPaymentRequest.

Operators

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