IC-POS adds support for ICRC-22 payment requests

Hey, I added support for ICRC-22 payment requests to the IC-POS example app.

IC-POS demonstrates a real world use case for ckBTC on the Internet Computer. It is a simple Point of Sale app that allows users to accept ckBTC payments.

App is live here: https://hngac-6aaaa-aaaal-qb6tq-cai.icp0.io/

Now you can charge a set amount, similar to Sumup and similar services. Enter the amount to charge and click the “Charge” button. The generated QR code will contain information about the token and amount to charge. The customer can then scan and pay with any wallet that supports the QR format, NNS for instance. Read more about ICRC-22 payment requests: ICRC-22 - Payment request formats · Issue #22 · dfinity/ICRC · GitHub

In addition to that, I also cleaned up the repo, removed external dependencies, made the setup processs simpler and in general tried to make this a better example to work with.

[0.2.0] - 2022-09-06


  • Principal pills are now clickable. Click to copy the principal id to the clipboard.


  • The icpos canister continuoulsy monitors the ckBTC ledger and sends notifications to merchants that choosen to receive email or sms. The ledger id used to be hardcode, now there is a function setLedgerId that can be called at runtime.

  • dfx.json: settings now included to run an ICRC-1 ledger and index locally.

  • Upgraded to latest versions of @dfinity/xxx packages.

  • Removed reliance on the HTTP ckBTC transaction API. Instead, IC-POS now uses the ledger canister directly to monitor transactions.

  • ckBTC balances are now updated in the UI after received transfers.