Authentification Token

Hello,
I have a Cuba web application and a mobile app which consumes REST API. On the mobile app there is a login/password authentification, and I would like to offer a authentification with QR Code.
The user connect to web app open a screen with a QR code, and if I scan the QR with the mobile APP the user is logged. I would to know if on ,on the web app i can generate a token that I can use in the mobile app to avoid the login/password function.
THanks