The QR is a URI with the ID, amount and maybe other stuff. It's a client-side implementation.
RuPay sure "works within the system" but is pretty much useless for international payments/subscriptions. Not really a VISA/MasterCard replacement.
(I don't know anything about UPI, but in Indonesia we use a similar system)
Its just a URI.
upi://pay?pa=payeeID&pn=payeeName
You can add things like &am= to prefill the amount. Merchant txns have reference IDs and all that stuff.this is why QR codes, especially ones with complicated encoded uris, are a security problem. they're very hard for leypeople to audit before doing the wrong thing