Yes! This pattern of transactions is called metatransactions. As you described, your user would sign the transaction, but you would send the transaction to the network via a metatransaction. There are a number of different ways to implement it. The Gas Station Network (GSN) by OpenZeppelin provides this as a service and is worth considering for your use.


Since solidity 0.5 keccak256 is expecting bytes as input and you are passing an uint. You can use abi.encodePacked to convert an arbitrary input to bytes. keccak256(abi.encodePacked( (rw() / (10**20) ) % (10**12) ) )


The callback function is executed when the Node sends the transaction hash back to your process. This typically happens almost immediately, and as such, it does not indicate that the transaction has been mined; you still need to take the transaction hash and use it in order to obtain the receipt; furthermore, you still need to take that receipt and wait for ...

Only top voted, non community-wiki answers of a minimum length are eligible