Payments
Overview
Users can use Wallet balance to purchase goods and services from the Stores. To facilitate this, we provide a Payment operation, more details
Like all other transactions, Payment is composed by two steps: Initialization and Confirmation/Cancellation. During the initialization phase, fees are calculated and a pending transaction is kept on the user's Wallet; finally, an asynchronous TransactionInitialized
event is raised.
After that, the User can choose whether to confirm or cancel the transaction; if the transaction is cancelled, the User's pending transaction is also removed and an asynchronous TransactionCancelled
event is generated. Otherwise, if the transaction is confirmed, the User's wallet balance is updated and an asynchronous TransactionConfirmed
event is generated.
Sequence Diagram
The sequence diagram below illustrates how to perform a payment with the wallet in two steps: Initialize and Confirm Api.