Hello @arunanksharan !
Welcome to MetaMask community !
I see the solution to the problem in the following sequence:
-
The QR code opens a web application with a payment page / a local coffeeshop application that is connected to a web3 provider
-
On the client side, using promises to get the hash of the transaction after successful completion / generate an error if not.
An example is given here:
-
Sending data over a secure connection to the server.
-
Interaction with the database / notification of the POS terminal application.