I want to generate a QRCode that has a link and a JSON object with it but it should be hidden. So this will generate a basic qrcode that has a link:
var QRCode = require('qrcode')
QRCode.toString('http://www.example.org/mypath',{type:'terminal'}, function (err, url) {
console.log(url)
})
If I have a Get to that path I will be able to use a query to add some additional information like so:
QRCode.toString('http://www.example.org/mypath?id=123abc&option=yes',{type:'terminal'}, function (err, url) {
console.log(url)
})
But I would like to send the id hidden in a JSON format or something not as a visible field.The purpose is that the client can generate a QRCode from it's account but after that I want him to be able to login with just the qrcode and pass some information like the option he chose.
To be more clear.He will be able to generate 3 qrcodes from his account to a question with options:Yes,No,Don't Know.He will have to scan the code with his phone(not logged in or from my app) and send him to my website with the option selected to the question.
So the question is how can I generate qrcode with a link but also a JSON object with details that are hidden until accessed by my site. I hope it makes sens ,thank you!
I guess you can't,you can pass text,json whatever but both link that sends you somewhere and something else not.You can pass queries to the link but if you want something hidden in the qr you can't.