I found some transaction inputs does not contain prev_out field, i.e. it does not have input address. It only has an output address. Does this mean this kind of transactions records the activities of mining new coins?


'tx': [{'hash': '2b1f06c2401d3b49a33c3f5ad5864c0bc70044c4068f9174546f3cfc1887d5ba', 'inputs': [{'script': '04ffff001d0138', 'sequence': 4294967295, 'witness': ''}], 'lock_time': 0, 'out': [{'addr': '1HwmP33SaknLYShXfjVU8KmVThU3JiuVgH', 'n': 0, 'script': '41045e071dedd1ed03721c6e9bba28fc276795421a378637fb41090192bb9f208630dcbac5862a3baeb9df3ca6e4e256b7fd2404824c20198ca1b004ee2197866433ac', 'spent': False, 'tx_index': 15066, 'type': 0, 'value': 5000000000}],

while for another transation:

{'hash': 'ee475443f1fbfff84ffba43ba092a70d291df233bd1428f3d09f7bd1a6054a1f', 'inputs': [{'prev_out': {'addr': '1CfD77hupeUvFwBPxZ2fA8iyWmVwQY22oh', 'n': 1, 'script': '76a9147fe34b97aeff4ab754770be5c8f12e2e95332fd488ac', 'spent': True, 'tx_index': 8845778, 'type': 0, 'value': 10212000000}, 'script': '483045022100e5e4749d539a163039769f52e1ebc8e6f62e39387d61e1a305bd722116cded6c022014924b745dd02194fe6b5cb8ac88ee8e9a2aede89e680dcea6169ea696e24d52012102b4b754609b46b5d09644c2161f1767b72b93847ce8154d795f95d31031a08aa2', 'sequence': 4294967295, 'witness': ''}], ...

the second one has a prev_out field while the first one does not

1 Answer 1


Transactions without prev_outs are known as coinbase transactions (not to be confused with transactions from the company named Coinbase) or coin generation transactions. They create outputs without needing any inputs to the transaction. Coinbase transactions are special transactions which are created miners and included as the first transaction in a block. They are what pays miners for their work.

There can only be one coinbase transaction per block, and it must be the first transaction of the block. The sum of the outputs must also meet certain constraints: it can be no more than the sum of the block subsidy and the sum of the transaction fees paid by all transactions in the block.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.