Revised API with QRCode