Creating a raw transaction, Please help
Creating a raw transaction, Please help
I want to create a raw transaction with python and i found the script Makes a transaction from the inputsoutputs is a list of [redemptionSatoshis, outputScript] def makeRawTransaction(outputTransactionHash, sourceIndex, scriptSig, outputs):def makeOutput(data):redemptionSatoshis, outputScript = datareturn (struct.pack("
- formattedOutputs = ''.join(map(makeOutput, outputs)) return ( "01000000" + # 4 bytes version "01" + # varint for number of inputs outputTransactionHash.decode('hex')[::-1].encode('hex') + # reverse outputTransactionHash struct.pack('
Comments
Post a Comment