Settings

Blockchain
Network
Unit
Language
Theme
Sound New Block

Transaction

3ea7c7ecf2a4f111dd3932fd125177d4f26197444b3ec6bf9b7c86f0b9c55ff0
Timestamp (utc)
2021-06-20 15:52:26
Fee Paid
0.00001232 BSV
(
0.00998874 BSV
-
0.00997642 BSV
)
Fee Rate
501 sat/KB
Version
1
Confirmations
297,977
Size Stats
2,459 B

3 Outputs

Total Output:
0.00997642 BSV
  • jrunM{"in":1,"ref":[],"out":["5db334c4f6a89a0cacbad3e510b1f45bbb598134b39bbf0928d0b1a5187f53b7"],"del":[],"cre":[],"exec":[{"op":"UPGRADE","data":[{"$jig":0},"class OrderLock {\n constructor(address, satoshis) {\n var a = \"b\";\n console.log(a);\n if (typeof address !== \"string\" || address.length < 27) {\n throw new TypeError(\"Invalid address\");\n }\n if (typeof satoshis !== \"number\" || !Number.isInteger(satoshis)) {\n throw new Error(\"Invalid satoshis\");\n }\n if (satoshis > Number.MAX_SAFE_INTEGER) {\n throw new Error(\"Invalid. Max: \" + Number.MAX_SAFE_INTEGER);\n }\n if (satoshis < 546) {\n throw new Error(\"Dust\");\n }\n this.address = address;\n this.satoshis = satoshis;\n }\n script() {\n const output = this.serializeOutput(this.address, this.satoshis);\n const hashOutput = this.sha256sha256(output);\n return (\n OrderLock.scriptTemplate.slice(0, 2) +\n hashOutput +\n OrderLock.scriptTemplate.slice(66)\n );\n }\n serializeOutput(address, satoshis) {\n console.log(address, satoshis);\n const satoshisHex = this.serializeSatoshis(satoshis);\n const satoshisHexBytes = Hex.stringToBytes(satoshisHex);\n const outputScriptBytes = Hex.stringToBytes(this.getP2PKHScript(address));\n const lengthBytes = [25];\n return satoshisHexBytes.concat(lengthBytes, outputScriptBytes);\n }\n serializeSatoshis(satoshis) {\n let numberHex = (\"0000000000000000\" + satoshis.toString(16)).slice(-16);\n return numberHex\n .match(/[a-fA-F0-9]{2}/g)\n .reverse()\n .join(\"\");\n }\n getP2PKHScript(address) {\n const decoded = Base58.decode(address);\n const hex = Hex.bytesToString(decoded);\n return asm(`OP_DUP OP_HASH160 ${hex} OP_EQUALVERIFY OP_CHECKSIG`);\n }\n sha256sha256(output) {\n return Hex.bytesToString(sha256(sha256(output)));\n }\n domain() {\n return 0;\n }\n }",{"deps":{}}]}]}
    https://whatsonchain.com/tx/3ea7c7ecf2a4f111dd3932fd125177d4f26197444b3ec6bf9b7c86f0b9c55ff0