I was rather surprised when I tried your sample code with a transaction
that was supposed to fail and it still said Ok for the resultCode, which
per your samples indicates a successful transaction, but in reality it
fails. How the response should be ...